public interface EntityViewConfiguration
| Modifier and Type | Method and Description |
|---|---|
EntityViewConfiguration |
addEntityView(Class<?> clazz)
Adds the given class to the set of known entity views.
|
EntityViewConfiguration |
addProperties(Properties extraProperties)
Add the given properties to the properties of the configuration.
|
EntityViewManager |
createEntityViewManager(CriteriaBuilderFactory criteriaBuilderFactory)
Creates a new entity view manager from this configuration.
|
EntityViewManager |
createEntityViewManager(CriteriaBuilderFactory criteriaBuilderFactory,
javax.persistence.EntityManagerFactory entityManagerFactory)
Deprecated.
Will be removed. Use
createEntityViewManager(CriteriaBuilderFactory) instead. |
EntityViewMapping |
createEntityViewMapping(Class<?> clazz)
Creates an entity view mapping based on the given annotated class
that can be further refined and finally added.
|
Map<Class<?>,BasicUserType<?>> |
getBasicUserTypes()
Returns the currently registered basic user types.
|
Collection<EntityViewMapping> |
getEntityViewMappings()
Returns the currently registered entity view mappings.
|
Set<Class<?>> |
getEntityViews()
Returns the currently known entity views.
|
Properties |
getProperties()
Returns all properties.
|
String |
getProperty(String propertyName)
Returns a property value by name.
|
Map<Class<?>,Map<Class<?>,TypeConverter<?,?>>> |
getTypeConverters()
Returns the currently registered type converters.
|
<Y> Map<Class<?>,TypeConverter<?,Y>> |
getTypeConverters(Class<Y> viewModelType)
Returns the currently registered type converters for the given view model type.
|
EntityViewConfiguration |
mergeProperties(Properties properties)
Adds the given properties to the properties of the configuration, without overriding existing values.
|
<X> EntityViewConfiguration |
registerBasicUserType(Class<X> clazz,
BasicUserType<X> userType)
Registers the given user type for the given class.
|
<X,Y> EntityViewConfiguration |
registerTypeConverter(Class<X> underlyingType,
Class<Y> viewModelType,
TypeConverter<X,Y> converter)
Registers the given converter for the given types.
|
EntityViewConfiguration |
setProperties(Properties properties)
Replace the properties of the configuration with the given properties.
|
EntityViewConfiguration |
setProperty(String propertyName,
String value)
Set a property value by name.
|
EntityViewConfiguration addEntityView(Class<?> clazz)
clazz - The class to be addedEntityViewMapping createEntityViewMapping(Class<?> clazz)
clazz - The annotated class to base the mapping on<X> EntityViewConfiguration registerBasicUserType(Class<X> clazz, BasicUserType<X> userType)
X - The type of the classclazz - The class for which to register the user typeuserType - The user type implementation<X,Y> EntityViewConfiguration registerTypeConverter(Class<X> underlyingType, Class<Y> viewModelType, TypeConverter<X,Y> converter)
X - The underlying typeY - The entity view model typeunderlyingType - The underlying type supported by the entity view type systemviewModelType - The entity view model typeconverter - The type converterEntityViewManager createEntityViewManager(CriteriaBuilderFactory criteriaBuilderFactory)
criteriaBuilderFactory - The criteria builder factory for which the entity view manager should be created@Deprecated EntityViewManager createEntityViewManager(CriteriaBuilderFactory criteriaBuilderFactory, javax.persistence.EntityManagerFactory entityManagerFactory)
createEntityViewManager(CriteriaBuilderFactory) instead.criteriaBuilderFactory - The criteria builder factory for which the entity view manager should be createdentityManagerFactory - The entity manager factory for which the entity view manager should be createdSet<Class<?>> getEntityViews()
Collection<EntityViewMapping> getEntityViewMappings()
Map<Class<?>,BasicUserType<?>> getBasicUserTypes()
Map<Class<?>,Map<Class<?>,TypeConverter<?,?>>> getTypeConverters()
<Y> Map<Class<?>,TypeConverter<?,Y>> getTypeConverters(Class<Y> viewModelType)
Y - The entity view model typeviewModelType - The view model typeProperties getProperties()
String getProperty(String propertyName)
propertyName - The name of the propertyEntityViewConfiguration setProperties(Properties properties)
properties - The new set of propertiesEntityViewConfiguration addProperties(Properties extraProperties)
extraProperties - The properties to add.EntityViewConfiguration mergeProperties(Properties properties)
properties - The properties to mergeEntityViewConfiguration setProperty(String propertyName, String value)
propertyName - The name of the property to setvalue - The new property valueCopyright © 2014–2018 Blazebit. All rights reserved.