Package africa.absa.inception.reference
Interface CountryRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Country,,CountryId> org.springframework.data.jpa.repository.JpaRepository<Country,,CountryId> org.springframework.data.repository.PagingAndSortingRepository<Country,,CountryId> org.springframework.data.repository.query.QueryByExampleExecutor<Country>,org.springframework.data.repository.Repository<Country,CountryId>
public interface CountryRepository
extends org.springframework.data.jpa.repository.JpaRepository<Country,CountryId>
The CountryRepository interface declares the repository for the Country domain
type.
- Author:
- Marcus Portmann
-
Method Summary
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, findAll, findAllById, flush, getById, getOne, saveAll, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findOne
-
Method Details
-
findAll
@Query("select c from Country c order by c.localeId, -c.sortIndex DESC, c.shortName") List<Country> findAll()Retrieve all the countries sorted by locale ID, sort index, and name. -
findByLocaleIdIgnoreCase
@Query("select c from Country c where upper(c.localeId) = upper(:localeId) order by c.localeId, -c.sortIndex DESC, c.shortName") List<Country> findByLocaleIdIgnoreCase(String localeId) Retrieve the countries for the specified locale sorted by locale ID, sort index, and name.- Parameters:
localeId- the Unicode locale identifier for the locale to retrieve the countries for- Returns:
- the countries for the specified locale sorted by locale ID, sort index, and name
-