Interface NotificaRicevutaRepository

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

@Repository public interface NotificaRicevutaRepository extends org.springframework.data.jpa.repository.JpaRepository<NotificaRicevuta,NotificaRicevutaKey>
  • Method Summary

    Modifier and Type
    Method
    Description
    findByIdUtente(Long idUtente)
    Query custom per recuperare la lista delle notifiche ricevute di un determinato utente tramite l'id.
    findByIdUtenteAndIdNotifica(Long idUtente, Long idNotifica)
    Query custom per recuperare una specifica Notifica Ricevuta.

    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

    • findByIdUtente

      @Query("SELECT n FROM NotificaRicevuta n WHERE n.idNotificaRicevuta.idUtente=?1 and n.isRead=false ") List<NotificaRicevuta> findByIdUtente(Long idUtente)
      Query custom per recuperare la lista delle notifiche ricevute di un determinato utente tramite l'id.
      Parameters:
      idUtente - Id dell' Utente
      Returns:
      Lista di notifiche ricevute di quell' Utente
    • findByIdUtenteAndIdNotifica

      @Query("SELECT n FROM NotificaRicevuta n WHERE n.idNotificaRicevuta.idUtente=?1 and n.idNotificaRicevuta.idNotifica=?2") NotificaRicevuta findByIdUtenteAndIdNotifica(Long idUtente, Long idNotifica)
      Query custom per recuperare una specifica Notifica Ricevuta.
      Parameters:
      idUtente - Id dell' Utente
      idNotifica - Id della Notidica
      Returns:
      Lista di notifiche ricevute di quell' Utente