Interface SubscriberRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Subscriber,,Long> org.springframework.data.jpa.repository.JpaRepository<Subscriber,,Long> org.springframework.data.repository.ListCrudRepository<Subscriber,,Long> org.springframework.data.repository.ListPagingAndSortingRepository<Subscriber,,Long> org.springframework.data.repository.PagingAndSortingRepository<Subscriber,,Long> org.springframework.data.repository.query.QueryByExampleExecutor<Subscriber>,org.springframework.data.repository.Repository<Subscriber,Long>
@Repository
public interface SubscriberRepository
extends org.springframework.data.jpa.repository.JpaRepository<Subscriber,Long>
Интерфейс представляет собой функциональность взаимодействия объекта Subscriber с базой данных.
- Author:
- mrGreenNV
-
Method Summary
Modifier and TypeMethodDescriptionfindSubscriberByUserAndFollower(User user, User follower) Выполняет поиск подписчика в базе данных.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, saveMethods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.ListCrudRepository
findAll, findAllById, saveAllMethods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOne
-
Method Details
-
findSubscriberByUserAndFollower
Выполняет поиск подписчика в базе данных.- Parameters:
user- пользователь.follower- подписчик пользователя.- Returns:
- Optional содержащий подписчика, если она была найдена, иначе - пустой.
-