Interface NotificationRepository

All Superinterfaces:
org.springframework.data.repository.CrudRepository<Notification,UUID>, org.springframework.data.jpa.repository.JpaRepository<Notification,UUID>, org.springframework.data.repository.ListCrudRepository<Notification,UUID>, org.springframework.data.repository.ListPagingAndSortingRepository<Notification,UUID>, org.springframework.data.repository.PagingAndSortingRepository<Notification,UUID>, org.springframework.data.repository.query.QueryByExampleExecutor<Notification>, org.springframework.data.repository.Repository<Notification,UUID>

@Repository public interface NotificationRepository extends org.springframework.data.jpa.repository.JpaRepository<Notification,UUID>
Repository for the Notification entity.
  • Method Summary

    Modifier and Type
    Method
    Description
    findAllByOfficeAndIsReadyAndRequestType(Office office, boolean isReady, RequestType requestType)
    Find all the notifications for the given office, ready status and request type.
    Find all the notifications for the user with the given id.

    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, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlush

    Methods inherited from interface org.springframework.data.repository.ListCrudRepository

    findAll, findAllById, saveAll

    Methods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.PagingAndSortingRepository

    findAll

    Methods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor

    count, exists, findAll, findBy, findOne
  • Method Details

    • findByUserId

      List<Notification> findByUserId(UUID id)
      Find all the notifications for the user with the given id.
      Parameters:
      id - the id of the user
      Returns:
      the list of notifications for the user with the given id
    • findAllByOfficeAndIsReadyAndRequestType

      List<Notification> findAllByOfficeAndIsReadyAndRequestType(Office office, boolean isReady, RequestType requestType)
      Find all the notifications for the given office, ready status and request type.
      Parameters:
      office - the office related to the notification to find
      isReady - filter for the ready status of the notification
      requestType - the type of the request related to the notification to find
      Returns:
      the list of notifications for the given office, ready status and request type