February 2019
Intermediate to advanced
442 pages
11h 46m
English
When we add a filter option for any entity, JHipster makes the necessary changes to the repository interface corresponding to that entity. In our case, the CountryRepository is now extending the JpaSpecificationExecutor interface, which is used to add Specification capabilities to the repository, as follows:
public interface CountryRepository extends JpaRepository<Country, Long>, JpaSpecificationExecutor<Country>
Spring Data JPA provides a Specification interface to execute the criteria query, which is used to retrieve values from the database with various criteria on database columns.