Interface UserRepository
-
- All Superinterfaces:
CrudRepository<User,UUID>,JpaRepository<User,UUID>,PagingAndSortingRepository<User,UUID>,QueryByExampleExecutor<User>,Repository<User,UUID>
public interface UserRepository extends JpaRepository<User,UUID>
This interface defines various methods that can be used to query the database.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Optional<User>findByExternalKey(UUID externalKey)Returns aUserobject that matches the external key.Optional<User>findByOauthKey(String oauthKey)Returns aUserobject that matches the OAuth key.Iterable<User>getAllByOrderByDisplayNameAsc()Returns a list ofUserobjects ordered by display name in ascending order.-
Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save
-
Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, saveAll, saveAllAndFlush, saveAndFlush
-
Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAll
-
Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findOne
-
-
-
-
Method Detail
-
findByOauthKey
Optional<User> findByOauthKey(String oauthKey)
Returns aUserobject that matches the OAuth key.- Parameters:
oauthKey- OAuth key in the form of a string.- Returns:
- An optional User object.
-
findByExternalKey
Optional<User> findByExternalKey(UUID externalKey)
Returns aUserobject that matches the external key.- Parameters:
externalKey- External key in the form of a universally unique identifier.- Returns:
- An optional User object.
-
-