Package com.example.restapi.repository
Interface BorrowingRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Borrowing,,Long> org.springframework.data.jpa.repository.JpaRepository<Borrowing,,Long> org.springframework.data.repository.ListCrudRepository<Borrowing,,Long> org.springframework.data.repository.ListPagingAndSortingRepository<Borrowing,,Long> org.springframework.data.repository.PagingAndSortingRepository<Borrowing,,Long> org.springframework.data.repository.query.QueryByExampleExecutor<Borrowing>,org.springframework.data.repository.Repository<Borrowing,Long>
-
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteByBookId(Long bookId) findActiveBorrowingByBookIdAndUserId(Long bookId, Long userId) findActiveBorrowingsByBookId(Long bookId, Long userId) findActiveBorrowingsByBookIdAndUserId(Long bookId, Long userId) findBooksBorrowedByUserId(Long userId) findBooksByUserId(Long userId) findBorrowingsByBookIdAndUserId(Long bookId, Long userId) findByBookId(Long bookId) findByUserId(Long userId) findLatestBorrowedBook(Long bookId, Long userId) findLatestBorrowing(Long bookId, Long userId) 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
-
findByUserId
-
findByBookId
-
deleteByBookId
-
findLatestBorrowing
-
findBooksByUserId
-
findBooksBorrowedByUserId
-
findBorrowingsByBookIdAndUserId
-
findActiveBorrowingsByBookIdAndUserId
-
findActiveBorrowingByBookIdAndUserId
-
findLatestBorrowedBook
-
findActiveBorrowingsByBookId
-