Package com.skava.auth.repository
Interface CollectionRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Collection,
,Long> org.springframework.data.jpa.repository.JpaRepository<Collection,
,Long> org.springframework.data.repository.ListCrudRepository<Collection,
,Long> org.springframework.data.repository.ListPagingAndSortingRepository<Collection,
,Long> org.springframework.data.repository.PagingAndSortingRepository<Collection,
,Long> org.springframework.data.repository.query.QueryByExampleExecutor<Collection>
,org.springframework.data.querydsl.QuerydslPredicateExecutor<Collection>
,org.springframework.data.repository.Repository<Collection,
Long>
public interface CollectionRepository
extends org.springframework.data.jpa.repository.JpaRepository<Collection,Long>, org.springframework.data.querydsl.QuerydslPredicateExecutor<Collection>
Repository class to represent the data access layer of the `collection` entity.
- Author:
- Infosys Equinox
-
Method Summary
Modifier and TypeMethodDescriptionboolean
existsByIdAndBusinessId
(Long collectionId, Long businessId) Service definition to check collection exists by id and business id.boolean
existsByNameIgnoreCaseAndBusinessId
(String collectionName, Long businessId) This method will check and return the result of collection duplication.org.springframework.data.domain.Page<Collection>
findAll
(org.springframework.data.jpa.domain.Specification<Collection> specification, org.springframework.data.domain.Pageable pageRequest) Service definition to find all collections.findByIdAndBusinessId
(Long collectionId, Long businessId) Service definition to find collection by id and business id.findTopByBusinessId
(Long businessId) Service definition to find collection by business id.Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, 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
Methods inherited from interface org.springframework.data.querydsl.QuerydslPredicateExecutor
count, exists, findAll, findAll, findAll, findAll, findAll, findBy, findOne
-
Method Details
-
findById
- Specified by:
findById
in interfaceorg.springframework.data.repository.CrudRepository<Collection,
Long>
-
findByIdAndBusinessId
Service definition to find collection by id and business id.- Parameters:
collectionId
- Identifier of collection.businessId
- Identifier of business.- Returns:
- Collection.
-
findTopByBusinessId
Service definition to find collection by business id.- Parameters:
businessId
- Identifier of business.- Returns:
- Collection.
-
existsByIdAndBusinessId
Service definition to check collection exists by id and business id.- Parameters:
collectionId
- Identifier of collection.businessId
- Identifier of business.- Returns:
- validation result.
-
findAll
org.springframework.data.domain.Page<Collection> findAll(org.springframework.data.jpa.domain.Specification<Collection> specification, org.springframework.data.domain.Pageable pageRequest) Service definition to find all collections.- Parameters:
specification
- aSpecification
ofCollection
objects.pageRequest
- Pageable- Returns:
- Collection
-
existsByNameIgnoreCaseAndBusinessId
This method will check and return the result of collection duplication.
-