T - resource type (entity or mapped dto)public class JpaRepositoryConfig<T> extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
JpaRepositoryConfig.Builder<T> |
| Modifier and Type | Method and Description |
|---|---|
static <E> JpaRepositoryConfig.Builder<E> |
builder(Class<E> entityClass)
Prepares a builder to configure a jpa repository for the given entity.
|
static <E,D> JpaRepositoryConfig.Builder<D> |
builder(Class<E> entityClass,
Class<D> dtoClass,
JpaMapper<E,D> mapper)
Prepares a builder to configure a jpa repository for the given entity class which is
mapped to a DTO with the provided mapper.
|
static <E> JpaRepositoryConfig<E> |
create(Class<E> entityClass)
Shortcut for builder(entityClass).build().
|
Class<?> |
getEntityClass() |
<M extends MetaInformation,L extends LinksInformation> |
getListClass() |
<E> JpaMapper<E,T> |
getMapper() |
<I extends Serializable> |
getRepositoryDecorator() |
<D,I extends Serializable,J extends Serializable> |
getRepositoryDecorator(Class<D> targetResourceType) |
Class<T> |
getResourceClass() |
DefaultResourceList<T> |
newResultList() |
public static <E> JpaRepositoryConfig<E> create(Class<E> entityClass)
entityClass - to directly exposepublic static <E> JpaRepositoryConfig.Builder<E> builder(Class<E> entityClass)
E - entity typeentityClass - to directly exposepublic static <E,D> JpaRepositoryConfig.Builder<D> builder(Class<E> entityClass, Class<D> dtoClass, JpaMapper<E,D> mapper)
E - entity typeD - dto typeentityClass - to usedtoClass - to exposemapper - to convert entity to dto and backpublic Class<?> getEntityClass()
public <M extends MetaInformation,L extends LinksInformation> Class<? extends ResourceListBase<T,M,L>> getListClass()
public DefaultResourceList<T> newResultList()
public <I extends Serializable> ResourceRepositoryDecorator<T,I> getRepositoryDecorator()
public <D,I extends Serializable,J extends Serializable> RelationshipRepositoryDecorator<T,I,D,J> getRepositoryDecorator(Class<D> targetResourceType)
Copyright © 2017. All Rights Reserved.