public class EntityGraphMapper extends Object implements EntityMapper
EntityMapper that is driven by an instance of MetaData.| Constructor and Description |
|---|
EntityGraphMapper(MetaData metaData,
MappingContext mappingContext)
Constructs a new
EntityGraphMapper that uses the given MetaData. |
| Modifier and Type | Method and Description |
|---|---|
void |
addWriteProtection(BiFunction<WriteProtectionTarget,Class<?>,Predicate<Object>> writeProtectionSupplier) |
CompileContext |
compileContext()
Returns compile context after multiple
EntityMapper.map(Object) operations were called |
CompileContext |
map(Object entity)
Processes the given object and any of its composite persistent objects and produces Cypher queries to persist their state
in Neo4j.
|
CompileContext |
map(Object entity,
int horizon)
Processes the given object and any of its composite persistent objects to the specified depth and produces Cypher queries
to persist their state in Neo4j.
|
public EntityGraphMapper(MetaData metaData, MappingContext mappingContext)
EntityGraphMapper that uses the given MetaData.metaData - The MetaData containing the mapping informationmappingContext - The MappingContext for the current sessionpublic void addWriteProtection(BiFunction<WriteProtectionTarget,Class<?>,Predicate<Object>> writeProtectionSupplier)
public CompileContext map(Object entity)
EntityMapperEntityMapper.compileContext() to get final CompileContext.map in interface EntityMapperentity - The "root" node of the object graph to persistCompileContext object containing the statements required to persist the given object to Neo4j, along
with a representation of the changes to be made by the Cypher statements never nullpublic CompileContext map(Object entity, int horizon)
EntityMapperEntityMapper.compileContext() to get final CompileContext.map in interface EntityMapperentity - The "root" node of the object graph to persisthorizon - The number of objects away from the "root" to traverse when looking for objects to mapCompileContext object containing the statements required to persist the given object to Neo4j, along
with a representation of the changes to be made by the Cypher statements never nullpublic CompileContext compileContext()
EntityMapperEntityMapper.map(Object) operations were calledcompileContext in interface EntityMapperCopyright © 2015–2020 Neo Technology, Inc.. All rights reserved.