<dd><code>org.springframework.data.repository.CrudRepository<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>,​java.lang.Long></code>, <code>org.springframework.data.jpa.repository.JpaRepository<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>,​java.lang.Long></code>, <code>org.springframework.data.repository.PagingAndSortingRepository<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>,​java.lang.Long></code>, <code>org.springframework.data.repository.query.QueryByExampleExecutor<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></code>, <code>org.springframework.data.repository.Repository<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>,​java.lang.Long></code></dd>
</dl>
<hr>
<pre>@Repository
public interface <spanclass="typeNameLabel">UserRepository</span>
extends org.springframework.data.jpa.repository.JpaRepository<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>,​java.lang.Long></pre>
<divclass="block">UserRepository.getByAuthority: Return list of: SELECT * FROM User WHERE email
= i.
Where i, ?1 are equale to variables.
UserRepository.getByToken: Return list of: SELECT * FROM User WHERE token =
i.
Where i, ?1 are equale to variables.
UserRepository.searchForUsers: Return list of: SELECT * FROM User WHERE (name
LIKE %?1% OR surname LIKE %?1%).
Where i, ?1 are equale to variables.
UserRepository.searchForUsers with role: Return list of: SELECT * FROM User
WHERE (name LIKE %?1% OR surname LIKE %?1%) AND role=?2").
<thclass="colFirst"scope="col">Modifier and Type</th>
<thclass="colSecond"scope="col">Method</th>
<thclass="colLast"scope="col">Description</th>
</tr>
</thead>
<tbody>
<trclass="altColor"id="i0">
<tdclass="colFirst"><code>java.util.List<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></code></td>
<thclass="colSecond"scope="row"><code><spanclass="memberNameLink"><ahref="#getAllByRole(com.plannaplan.types.UserRoles)">getAllByRole</a></span>​(<ahref="../types/UserRoles.html"title="enum in com.plannaplan.types">UserRoles</a> role)</code></th>
<tdclass="colLast"> </td>
</tr>
<trclass="rowColor"id="i1">
<tdclass="colFirst"><code>java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></code></td>
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE email = ?1 OR usosId = ?1")
</span><spanclass="returnType">java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getByAuthority</span>​(<spanclass="arguments">@Param("authority")
java.lang.String authority)</span></div>
<divclass="block">return user by given authority</div>
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE email = ?1")
</span><spanclass="returnType">java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getByEmail</span>​(<spanclass="arguments">@Param("authority")
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE refreshToken = ?1")
</span><spanclass="returnType">java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getByRefreshToken</span>​(<spanclass="arguments">@Param("refreshToken")
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE token = ?1")
</span><spanclass="returnType">java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getByToken</span>​(<spanclass="arguments">@Param("token")
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE (name LIKE %?1% OR surname LIKE %?1%)")
</span><spanclass="returnType">java.util.List<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">searchForUsers</span>​(<spanclass="arguments">@Param("query")
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE (name LIKE %?1% OR surname LIKE %?1%) AND role=?2")
</span><spanclass="returnType">java.util.List<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">searchForUsers</span>​(<spanclass="arguments">@Param("query")
java.lang.String query,
@Param("role")
<ahref="../types/UserRoles.html"title="enum in com.plannaplan.types">UserRoles</a> role)</span></div>
<divclass="block">search for user with given query</div>
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE role=?1")
</span><spanclass="returnType">java.util.List<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getAllByRole</span>​(<spanclass="arguments">@Param("role")
<ahref="../types/UserRoles.html"title="enum in com.plannaplan.types">UserRoles</a> role)</span></div>
<divclass="memberSignature"><spanclass="annotations">@Query("FROM User WHERE usosId = ?1")
</span><spanclass="returnType">java.util.Optional<<ahref="../entities/User.html"title="class in com.plannaplan.entities">User</a>></span> <spanclass="memberName">getByUsosId</span>​(<spanclass="arguments">@Param("usosId")