Spring Data Neo4j

org.springframework.data.neo4j.fieldaccess
Class OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor

java.lang.Object
  extended by org.springframework.data.neo4j.fieldaccess.AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>
      extended by org.springframework.data.neo4j.fieldaccess.OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor
All Implemented Interfaces:
FieldAccessor
Enclosing class:
OneToNRelationshipEntityFieldAccessorFactory

public static class OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor
extends AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>


Field Summary
 
Fields inherited from class org.springframework.data.neo4j.fieldaccess.AbstractNodeRelationshipFieldAccessor
direction, property, relatedType, template, type
 
Constructor Summary
OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor(org.neo4j.graphdb.RelationshipType type, org.neo4j.graphdb.Direction direction, Class<?> elementClass, Neo4jTemplate template, Neo4jPersistentProperty property)
           
 
Method Summary
protected  org.neo4j.graphdb.Node getState(Object entity)
           
protected  Iterable<org.neo4j.graphdb.Relationship> getStatesFromEntity(Object entity)
           
 Object getValue(Object entity)
           
 boolean isWriteable(Object entity)
           
protected  org.neo4j.graphdb.Relationship obtainSingleRelationship(org.neo4j.graphdb.Node start, org.neo4j.graphdb.Relationship end)
           
 Object setValue(Object entity, Object newVal)
          handles field write modification.
 
Methods inherited from class org.springframework.data.neo4j.fieldaccess.AbstractNodeRelationshipFieldAccessor
checkTargetIsSetOfNodebacked, checkUnderlyingNode, createAddedRelationships, createEntitySetFromRelationshipEndNodes, createManagedSet, createSingleRelationship, getDefaultImplementation, getOrCreateState, removeMissingRelationships
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor

public OneToNRelationshipEntityFieldAccessorFactory.OneToNRelationshipEntityFieldAccessor(org.neo4j.graphdb.RelationshipType type,
                                                                                          org.neo4j.graphdb.Direction direction,
                                                                                          Class<?> elementClass,
                                                                                          Neo4jTemplate template,
                                                                                          Neo4jPersistentProperty property)
Method Detail

setValue

public Object setValue(Object entity,
                       Object newVal)
Description copied from interface: FieldAccessor
handles field write modification.

Returns:
the written value or a DoReturn wrapper with the written value or null. DoReturn indicates that the aspect should not proceed to the original field access but instead return immediately.

isWriteable

public boolean isWriteable(Object entity)
Specified by:
isWriteable in interface FieldAccessor
Overrides:
isWriteable in class AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>
Returns:
false for read only or computed fields, true otherwise

getValue

public Object getValue(Object entity)
Returns:
the value or a DoReturn wrapper with the value for the field. DoReturn indicates that the aspect should not proceed to the original field access but instead return immediately.

getStatesFromEntity

protected Iterable<org.neo4j.graphdb.Relationship> getStatesFromEntity(Object entity)
Specified by:
getStatesFromEntity in class AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>

obtainSingleRelationship

protected org.neo4j.graphdb.Relationship obtainSingleRelationship(org.neo4j.graphdb.Node start,
                                                                  org.neo4j.graphdb.Relationship end)
Specified by:
obtainSingleRelationship in class AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>

getState

protected org.neo4j.graphdb.Node getState(Object entity)
Specified by:
getState in class AbstractNodeRelationshipFieldAccessor<org.neo4j.graphdb.Node,org.neo4j.graphdb.Relationship>

Spring Data Neo4j

Copyright © 2011 SpringSource. All Rights Reserved.