public class SimpleJpaEntityGraphRepository<T,ID extends Serializable> extends org.springframework.data.jpa.repository.support.SimpleJpaRepository<T,ID> implements JpaEntityGraphRepository<T,ID>, JpaEntityGraphSpecificationExecutor<T>
SimpleJpaRepository that supports EntityGraph passed through method arguments.
Created on 22/11/16.| Constructor and Description |
|---|
SimpleJpaEntityGraphRepository(Class<T> domainClass,
javax.persistence.EntityManager em) |
SimpleJpaEntityGraphRepository(org.springframework.data.jpa.repository.support.JpaEntityInformation<T,?> entityInformation,
javax.persistence.EntityManager entityManager) |
| Modifier and Type | Method and Description |
|---|---|
List<T> |
findAll(EntityGraph entityGraph)
Returns all instances of the type.
|
<S extends T> |
findAll(org.springframework.data.domain.Example<S> example,
EntityGraph entityGraph)
Returns the number of instances matching the given
Example. |
<S extends T> |
findAll(org.springframework.data.domain.Example<S> example,
org.springframework.data.domain.Pageable pageable,
EntityGraph entityGraph)
Returns a
Page of entities matching the given Example. |
<S extends T> |
findAll(org.springframework.data.domain.Example<S> example,
org.springframework.data.domain.Sort sort,
EntityGraph entityGraph)
Returns all entities matching the given
Example applying the given Sort. |
List<T> |
findAll(Iterable<ID> ids,
EntityGraph entityGraph)
Returns all instances of the type with the given IDs.
|
org.springframework.data.domain.Page<T> |
findAll(org.springframework.data.domain.Pageable pageable,
EntityGraph entityGraph)
Returns a
Page of entities meeting the paging restriction provided in the Pageable object. |
List<T> |
findAll(org.springframework.data.domain.Sort sort,
EntityGraph entityGraph)
Returns all entities sorted by the given options.
|
List<T> |
findAll(org.springframework.data.jpa.domain.Specification<T> spec,
EntityGraph entityGraph)
Returns all entities matching the given
Specification. |
org.springframework.data.domain.Page<T> |
findAll(org.springframework.data.jpa.domain.Specification<T> spec,
org.springframework.data.domain.Pageable pageable,
EntityGraph entityGraph)
Returns a
Page of entities matching the given Specification. |
List<T> |
findAll(org.springframework.data.jpa.domain.Specification<T> spec,
org.springframework.data.domain.Sort sort,
EntityGraph entityGraph)
Returns all entities matching the given
Specification and Sort. |
<S extends T> |
findOne(org.springframework.data.domain.Example<S> example,
EntityGraph entityGraph)
Returns a single entity matching the given
Example or null if none was found. |
T |
findOne(ID id,
EntityGraph entityGraph)
Retrieves an entity by its id.
|
T |
findOne(org.springframework.data.jpa.domain.Specification<T> spec,
EntityGraph entityGraph)
Returns a single entity matching the given
Specification. |
count, count, count, delete, delete, delete, deleteAll, deleteAllInBatch, deleteInBatch, exists, exists, findAll, findAll, findAll, findAll, findAll, findAll, findAll, findAll, findAll, findAll, findOne, findOne, findOne, flush, getCountQuery, getCountQuery, getDomainClass, getOne, getQuery, getQuery, getQuery, getQuery, getQueryHints, getRepositoryMethodMetadata, readPage, readPage, save, save, saveAndFlush, setRepositoryMethodMetadataclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdeleteAllInBatch, deleteInBatch, findAll, findAll, findAll, findAll, findAll, flush, getOne, save, saveAndFlushfindAllcount, delete, delete, delete, deleteAll, exists, findOne, savepublic SimpleJpaEntityGraphRepository(org.springframework.data.jpa.repository.support.JpaEntityInformation<T,?> entityInformation, javax.persistence.EntityManager entityManager)
public T findOne(org.springframework.data.jpa.domain.Specification<T> spec, EntityGraph entityGraph)
JpaEntityGraphSpecificationExecutorSpecification.findOne in interface JpaEntityGraphSpecificationExecutor<T>public List<T> findAll(org.springframework.data.jpa.domain.Specification<T> spec, EntityGraph entityGraph)
JpaEntityGraphSpecificationExecutorSpecification.findAll in interface JpaEntityGraphSpecificationExecutor<T>public org.springframework.data.domain.Page<T> findAll(org.springframework.data.jpa.domain.Specification<T> spec, org.springframework.data.domain.Pageable pageable, EntityGraph entityGraph)
JpaEntityGraphSpecificationExecutorPage of entities matching the given Specification.findAll in interface JpaEntityGraphSpecificationExecutor<T>public List<T> findAll(org.springframework.data.jpa.domain.Specification<T> spec, org.springframework.data.domain.Sort sort, EntityGraph entityGraph)
JpaEntityGraphSpecificationExecutorSpecification and Sort.findAll in interface JpaEntityGraphSpecificationExecutor<T>public <S extends T> org.springframework.data.domain.Page<S> findAll(org.springframework.data.domain.Example<S> example, org.springframework.data.domain.Pageable pageable, EntityGraph entityGraph)
JpaEntityGraphRepositoryPage of entities matching the given Example. In case no match could be found, an empty
Page is returned.findAll in interface JpaEntityGraphRepository<T,ID extends Serializable>example - can be null.pageable - can be null.entityGraph - can be null.Page of entities matching the given Example.public <S extends T> S findOne(org.springframework.data.domain.Example<S> example, EntityGraph entityGraph)
JpaEntityGraphRepositoryExample or null if none was found.findOne in interface JpaEntityGraphRepository<T,ID extends Serializable>example - can be null.entityGraph - can be null.Example or null if none was found.public T findOne(ID id, EntityGraph entityGraph)
JpaEntityGraphRepositoryfindOne in interface JpaEntityGraphRepository<T,ID extends Serializable>id - must not be null.entityGraph - can be null.public org.springframework.data.domain.Page<T> findAll(org.springframework.data.domain.Pageable pageable, EntityGraph entityGraph)
JpaEntityGraphRepositoryPage of entities meeting the paging restriction provided in the Pageable object.findAll in interface JpaEntityGraphRepository<T,ID extends Serializable>entityGraph - can be null.public <S extends T> List<S> findAll(org.springframework.data.domain.Example<S> example, org.springframework.data.domain.Sort sort, EntityGraph entityGraph)
JpaEntityGraphRepositoryExample applying the given Sort. In case no match could be
found an empty Iterable is returned.findAll in interface JpaEntityGraphRepository<T,ID extends Serializable>example - can be null.sort - the Sort specification to sort the results by, must not be null.entityGraph - can be null.Example.public <S extends T> List<S> findAll(org.springframework.data.domain.Example<S> example, EntityGraph entityGraph)
JpaEntityGraphRepositoryExample.findAll in interface JpaEntityGraphRepository<T,ID extends Serializable>example - the Example to count instances for, can be null.entityGraph - can be null.Example.public List<T> findAll(Iterable<ID> ids, EntityGraph entityGraph)
JpaEntityGraphRepositoryfindAll in interface JpaEntityGraphRepository<T,ID extends Serializable>entityGraph - can be null.public List<T> findAll(org.springframework.data.domain.Sort sort, EntityGraph entityGraph)
JpaEntityGraphRepositoryfindAll in interface JpaEntityGraphRepository<T,ID extends Serializable>entityGraph - can be null.public List<T> findAll(EntityGraph entityGraph)
JpaEntityGraphRepositoryfindAll in interface JpaEntityGraphRepository<T,ID extends Serializable>entityGraph - can be null.Copyright © 2017 Cosium. All rights reserved.