public class CouchbaseMappingContext extends AbstractMappingContext<BasicCouchbasePersistentEntity<?>,CouchbasePersistentProperty> implements ApplicationContextAware
MappingContext for Couchbase using
BasicCouchbasePersistentEntity and BasicCouchbasePersistentProperty as primary abstractions.| Constructor and Description |
|---|
CouchbaseMappingContext() |
| Modifier and Type | Method and Description |
|---|---|
protected <T> BasicCouchbasePersistentEntity<?> |
createPersistentEntity(TypeInformation<T> typeInformation)
Creates a concrete entity based out of the type information passed.
|
protected CouchbasePersistentProperty |
createPersistentProperty(Property property,
BasicCouchbasePersistentEntity<?> owner,
SimpleTypeHolder simpleTypeHolder)
Creates a concrete property based on the field information and entity.
|
void |
setApplicationContext(ApplicationContext applicationContext)
Sets (or overrides) the current application context.
|
void |
setFieldNamingStrategy(FieldNamingStrategy fieldNamingStrategy)
Configures the
FieldNamingStrategy to be used to determine the field name if no manual mapping is applied. |
addPersistentEntity, addPersistentEntity, afterPropertiesSet, getManagedTypes, getPersistentEntities, getPersistentEntity, getPersistentEntity, getPersistentEntity, getPersistentPropertyPath, getPersistentPropertyPath, getPersistentPropertyPath, hasPersistentEntityFor, initialize, setApplicationEventPublisher, setInitialEntitySet, setSimpleTypeHolder, setStrict, shouldCreatePersistentEntityForclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetRequiredPersistentEntity, getRequiredPersistentEntity, getRequiredPersistentEntitypublic void setFieldNamingStrategy(FieldNamingStrategy fieldNamingStrategy)
FieldNamingStrategy to be used to determine the field name if no manual mapping is applied.
Defaults to a strategy using the plain property name.fieldNamingStrategy - the FieldNamingStrategy to be used to determine the field name if no manual
mapping is applied.protected <T> BasicCouchbasePersistentEntity<?> createPersistentEntity(TypeInformation<T> typeInformation)
createPersistentEntity in class AbstractMappingContext<BasicCouchbasePersistentEntity<?>,CouchbasePersistentProperty>T - the type for the corresponding type information.typeInformation - type information of the entity to create.protected CouchbasePersistentProperty createPersistentProperty(Property property, BasicCouchbasePersistentEntity<?> owner, SimpleTypeHolder simpleTypeHolder)
createPersistentProperty in class AbstractMappingContext<BasicCouchbasePersistentEntity<?>,CouchbasePersistentProperty>property - the property descriptor.owner - the entity which owns the property.simpleTypeHolder - the type holder.public void setApplicationContext(ApplicationContext applicationContext) throws BeansException
setApplicationContext in interface ApplicationContextAwareapplicationContext - the application context to be assigned.BeansException - if the context can not be set properly.Copyright © 2011–2018 Pivotal Software, Inc.. All rights reserved.