public class MappingContext extends Object
| Constructor and Description |
|---|
MappingContext(MetaData metaData) |
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
void |
clear(Class<?> type)
purges all information about objects of the supplied type
from the mapping context.
|
void |
clear(Object entity)
purges all information about this object from the mapping context
|
void |
deregister(Object entity,
Long id)
Deregisters an object from the mapping context
- removes the object instance from the typeRegister(s)
- removes the object id from the nodeEntityRegister
- removes any relationship entities from relationshipEntityRegister if they have this object either as start or end node
|
Map<Long,Object> |
getAll(Class<?> type) |
Object |
getNodeEntity(Long id) |
Object |
getRelationshipEntity(Long relationshipId) |
boolean |
isDirty(Object entity) |
boolean |
isRegisteredRelationship(MappedRelationship relationship) |
Set<MappedRelationship> |
mappedRelationships() |
Object |
registerNodeEntity(Object entity,
Long id) |
void |
registerRelationship(MappedRelationship relationship) |
Object |
registerRelationshipEntity(Object relationshipEntity,
Long id) |
void |
remember(Object entity) |
void |
replace(Object entity,
Long id) |
public MappingContext(MetaData metaData)
public void deregister(Object entity, Long id)
entity - the object to deregisterid - the id of the object in Neo4jpublic void remember(Object entity)
public boolean isDirty(Object entity)
public boolean isRegisteredRelationship(MappedRelationship relationship)
public Set<MappedRelationship> mappedRelationships()
public void registerRelationship(MappedRelationship relationship)
public void clear()
public Object registerRelationshipEntity(Object relationshipEntity, Long id)
public void clear(Class<?> type)
type - the type whose object references and relationship mappings we want to purgepublic void clear(Object entity)
entity - the type whose object references and relationship mappings we want to purgeCopyright © 2016 Neo Technology, Inc.. All rights reserved.