public interface EntityViewConfiguration
Modifier and Type | Method | Description |
---|---|---|
EntityViewConfiguration |
addEntityView(java.lang.Class<?> clazz) |
Adds the given class to the set of known entity views.
|
EntityViewConfiguration |
addProperties(java.util.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(java.lang.Class<?> clazz) |
Creates an entity view mapping based on the given annotated class
that can be further refined and finally added.
|
java.util.Map<java.lang.Class<?>,BasicUserType<?>> |
getBasicUserTypes() |
Returns the currently registered basic user types.
|
java.util.Collection<EntityViewMapping> |
getEntityViewMappings() |
Returns the currently registered entity view mappings.
|
java.util.Set<java.lang.Class<?>> |
getEntityViews() |
Returns the currently known entity views.
|
java.util.Properties |
getProperties() |
Returns all properties.
|
java.lang.String |
getProperty(java.lang.String propertyName) |
Returns a property value by name.
|
java.util.Map<java.lang.Class<?>,java.util.Map<java.lang.Class<?>,TypeConverter<?,?>>> |
getTypeConverters() |
Returns the currently registered type converters.
|
<Y> java.util.Map<java.lang.Class<?>,TypeConverter<?,Y>> |
getTypeConverters(java.lang.Class<Y> viewModelType) |
Returns the currently registered type converters for the given view model type.
|
EntityViewConfiguration |
mergeProperties(java.util.Properties properties) |
Adds the given properties to the properties of the configuration, without overriding existing values.
|
<X> EntityViewConfiguration |
registerBasicUserType(java.lang.Class<X> clazz,
BasicUserType<X> userType) |
Registers the given user type for the given class.
|
<X,Y> EntityViewConfiguration |
registerTypeConverter(java.lang.Class<X> underlyingType,
java.lang.Class<Y> viewModelType,
TypeConverter<X,Y> converter) |
Registers the given converter for the given types.
|
EntityViewConfiguration |
setProperties(java.util.Properties properties) |
Replace the properties of the configuration with the given properties.
|
EntityViewConfiguration |
setProperty(java.lang.String propertyName,
java.lang.String value) |
Set a property value by name.
|
EntityViewConfiguration addEntityView(java.lang.Class<?> clazz)
clazz
- The class to be addedEntityViewMapping createEntityViewMapping(java.lang.Class<?> clazz)
clazz
- The annotated class to base the mapping on<X> EntityViewConfiguration registerBasicUserType(java.lang.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(java.lang.Class<X> underlyingType, java.lang.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 createdjava.util.Set<java.lang.Class<?>> getEntityViews()
java.util.Collection<EntityViewMapping> getEntityViewMappings()
java.util.Map<java.lang.Class<?>,BasicUserType<?>> getBasicUserTypes()
java.util.Map<java.lang.Class<?>,java.util.Map<java.lang.Class<?>,TypeConverter<?,?>>> getTypeConverters()
<Y> java.util.Map<java.lang.Class<?>,TypeConverter<?,Y>> getTypeConverters(java.lang.Class<Y> viewModelType)
Y
- The entity view model typeviewModelType
- The view model typejava.util.Properties getProperties()
java.lang.String getProperty(java.lang.String propertyName)
propertyName
- The name of the propertyEntityViewConfiguration setProperties(java.util.Properties properties)
properties
- The new set of propertiesEntityViewConfiguration addProperties(java.util.Properties extraProperties)
extraProperties
- The properties to add.EntityViewConfiguration mergeProperties(java.util.Properties properties)
properties
- The properties to mergeEntityViewConfiguration setProperty(java.lang.String propertyName, java.lang.String value)
propertyName
- The name of the property to setvalue
- The new property valueCopyright © 2014–2018 Blazebit. All rights reserved.