Package balu.pizza.webapp.repositiries
Interface PizzaRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Pizza,
,Integer> org.springframework.data.jpa.repository.JpaRepository<Pizza,
,Integer> org.springframework.data.repository.PagingAndSortingRepository<Pizza,
,Integer> org.springframework.data.repository.query.QueryByExampleExecutor<Pizza>
,org.springframework.data.repository.Repository<Pizza,
Integer>
@Repository
public interface PizzaRepository
extends org.springframework.data.jpa.repository.JpaRepository<Pizza,Integer>
Repository for Entity Base
-
Method Summary
Modifier and TypeMethodDescriptionfindByCafes
(Cafe cafe, org.springframework.data.domain.Sort name) Search for pizza by entity CafefindByName
(String name) Search pizza by namefindByPersons
(Person person) Search for pizza by entity PersonfindDistinctPizzaByBase_SizeLikeIgnoreCase
(String size, org.springframework.data.domain.Sort name) Search for pizza by field size in entity baseMethods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, save
Methods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAllById, flush, getById, getOne, getReferenceById, saveAll, saveAllAndFlush, saveAndFlush
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
-
Method Details
-
findDistinctPizzaByBase_SizeLikeIgnoreCase
List<Pizza> findDistinctPizzaByBase_SizeLikeIgnoreCase(String size, org.springframework.data.domain.Sort name) Search for pizza by field size in entity base- Parameters:
size
- Sizename
- the list will be sorted by pizza name- Returns:
- Sorted by name, the list of pizzas that have the size 'size'
-
findByPersons
Search for pizza by entity Person- Parameters:
person
- Entity Person- Returns:
- list of pizzas that are associated with the user
-
findByName
Search pizza by name- Parameters:
name
-- Returns:
- An object that may contain a Pizza or be empty
-
findByCafes
Search for pizza by entity Cafe- Parameters:
cafe
-name
- The list will be sorted by name- Returns:
- list of pizzas that are associated with the cafe
-