Interface SportRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Sport,,Integer> org.springframework.data.jpa.repository.JpaRepository<Sport,,Integer> org.springframework.data.repository.ListCrudRepository<Sport,,Integer> org.springframework.data.repository.ListPagingAndSortingRepository<Sport,,Integer> org.springframework.data.repository.PagingAndSortingRepository<Sport,,Integer> org.springframework.data.repository.query.QueryByExampleExecutor<Sport>,org.springframework.data.repository.Repository<Sport,Integer>
@Repository
public interface SportRepository
extends org.springframework.data.jpa.repository.JpaRepository<Sport,Integer>
Spring Data JPA repository for
Sport entities.
Provides standard CRUD operations as well as custom query methods for retrieving sports by their active status.
- Author:
- SportTrack Team
-
Method Summary
Modifier and TypeMethodDescriptionfindAllByActive(boolean active) Finds all sports matching the given active status.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
-
findAllByActive
Finds all sports matching the given active status.- Parameters:
active-trueto retrieve only active sports,falsefor inactive- Returns:
- a list of sports matching the specified active status
-