@java.lang.SuppressWarnings("rawtypes") public abstract class AbstractMappingContext extends java.lang.Object implements Initializable, MappingContext
Abstract implementation of the MappingContext interface.
Modifiers | Name | Description |
---|---|---|
static java.lang.String |
CONFIGURATION_PREFIX |
|
static java.lang.String |
GROOVY_PROXY_FACTORY_NAME |
|
static java.lang.String |
JAVASIST_PROXY_FACTORY |
|
protected org.springframework.core.convert.support.GenericConversionService |
conversionService |
|
protected java.util.Map<PersistentEntity, org.springframework.validation.Validator> |
entityValidators |
|
protected java.util.Collection<Listener> |
eventListeners |
|
protected java.util.Collection<PersistentEntity> |
persistentEntities |
|
protected java.util.Map<PersistentEntity, java.util.Map<java.lang.String, PersistentEntity>> |
persistentEntitiesByDiscriminator |
|
protected java.util.Map<java.lang.String, PersistentEntity> |
persistentEntitiesByName |
|
protected java.util.Map<PersistentEntity, java.util.Collection<PersistentEntity>> |
persistentEntitiesByParent |
|
protected ProxyFactory |
proxyFactory |
|
protected ValidatorRegistry |
validatorRegistry |
Constructor and description |
---|
AbstractMappingContext() |
AbstractMappingContext(ConnectionSourceSettings settings) |
Type Params | Return Type | Name and description |
---|---|---|
|
public void |
addEntityValidator(PersistentEntity entity, org.springframework.validation.Validator validator) Adds a validator for an entity |
|
public PersistentEntity |
addExternalPersistentEntity(java.lang.Class javaClass) Adds an external PersistentEntity instance, one that is not managed and persisted by this context |
|
public void |
addMappingContextListener(MappingContext.Listener listener) |
|
public java.util.Collection<PersistentEntity> |
addPersistentEntities(java.lang.Class javaClasses) |
|
public PersistentEntity |
addPersistentEntity(java.lang.Class javaClass, boolean override) Adds a PersistentEntity instance |
|
public PersistentEntity |
addPersistentEntity(java.lang.Class javaClass) Adds a PersistentEntity instance |
|
public void |
addTypeConverter(org.springframework.core.convert.converter.Converter converter) |
|
public void |
configure(org.springframework.core.env.PropertyResolver configuration) |
|
public PersistentEntity |
createEmbeddedEntity(java.lang.Class type) |
|
public EntityAccess |
createEntityAccess(PersistentEntity entity, java.lang.Object instance) |
|
protected abstract PersistentEntity |
createPersistentEntity(java.lang.Class javaClass) |
|
protected PersistentEntity |
createPersistentEntity(java.lang.Class javaClass, boolean external) |
|
public java.util.Collection<PersistentEntity> |
getChildEntities(PersistentEntity root) |
|
public PersistentEntity |
getChildEntityByDiscriminator(PersistentEntity root, java.lang.String discriminator) |
|
public org.springframework.core.convert.ConversionService |
getConversionService() |
|
public org.springframework.core.convert.converter.ConverterRegistry |
getConverterRegistry() |
|
public java.util.Collection<PersistentEntity> |
getDirectChildEntities(PersistentEntity root) |
|
public EntityReflector |
getEntityReflector(PersistentEntity entity) Obtains a EntityReflector instance for the given entity |
|
public org.springframework.validation.Validator |
getEntityValidator(PersistentEntity entity) Retrieves a validator for an entity |
|
public abstract MappingFactory |
getMappingFactory() |
|
public MultiTenancyMode |
getMultiTenancyMode() |
|
public java.util.Collection<PersistentEntity> |
getPersistentEntities() |
|
public PersistentEntity |
getPersistentEntity(java.lang.String name) |
|
public ProxyFactory |
getProxyFactory() |
|
public ProxyHandler |
getProxyHandler() |
|
public ValidatorRegistry |
getValidatorRegistry() |
|
protected void |
initialize(ConnectionSourceSettings settings) |
|
public void |
initialize() |
|
public boolean |
isInInheritanceHierarchy(PersistentEntity entity) Returns true if the given entity is in an inheritance hierarchy |
|
public boolean |
isInitialized() |
|
public boolean |
isPersistentEntity(java.lang.Class type) |
|
public boolean |
isPersistentEntity(java.lang.Object value) |
|
protected boolean |
isValidMappingStrategy(java.lang.Class javaClass, java.lang.Object mappingStrategy) |
|
protected java.lang.Object |
resolveMappingStrategy(java.lang.Class javaClass) |
|
public void |
setCanInitializeEntities(boolean canInitializeEntities) |
|
public void |
setProxyFactory(ProxyFactory factory) |
|
public void |
setValidatorRegistry(ValidatorRegistry validatorRegistry) |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Adds a validator for an entity
entity
- The PersistentEntity The entityvalidator
- The validator The validatorAdds an external PersistentEntity instance, one that is not managed and persisted by this context
javaClass
- The Java class representing the entityAdds a PersistentEntity instance
javaClass
- The Java class representing the entityoverride
- Whether to override an existing entityAdds a PersistentEntity instance
javaClass
- The Java class representing the entityObtains a EntityReflector instance for the given entity
entity
- The entityRetrieves a validator for an entity
entity
- The entity The entityReturns true if the given entity is in an inheritance hierarchy
entity
- The entity