Spring Data Graph

org.springframework.data.neo4j.fieldaccess
Class PropertyFieldAccessorFactory.PropertyFieldAccessor

java.lang.Object
  extended by org.springframework.data.neo4j.fieldaccess.PropertyFieldAccessorFactory.PropertyFieldAccessor
All Implemented Interfaces:
FieldAccessor<GraphBacked<org.neo4j.graphdb.PropertyContainer>>
Direct Known Subclasses:
ConvertingNodePropertyFieldAccessorFactory.ConvertingNodePropertyFieldAccessor
Enclosing class:
PropertyFieldAccessorFactory

public static class PropertyFieldAccessorFactory.PropertyFieldAccessor
extends Object
implements FieldAccessor<GraphBacked<org.neo4j.graphdb.PropertyContainer>>


Field Summary
protected  Class<?> fieldType
           
protected  String propertyName
           
 
Constructor Summary
PropertyFieldAccessorFactory.PropertyFieldAccessor(ConversionService conversionService, String propertyName, Class fieldType)
           
 
Method Summary
protected  Object doGetValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)
           
 Object getValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)
           
 boolean isWriteable(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)
           
 Object setValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked, Object newVal)
          handles field write modification.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

propertyName

protected final String propertyName

fieldType

protected final Class<?> fieldType
Constructor Detail

PropertyFieldAccessorFactory.PropertyFieldAccessor

public PropertyFieldAccessorFactory.PropertyFieldAccessor(ConversionService conversionService,
                                                          String propertyName,
                                                          Class fieldType)
Method Detail

isWriteable

public boolean isWriteable(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)
Specified by:
isWriteable in interface FieldAccessor<GraphBacked<org.neo4j.graphdb.PropertyContainer>>
Returns:
false for read only or computed fields, true otherwise

setValue

public Object setValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked,
                       Object newVal)
Description copied from interface: FieldAccessor
handles field write modification.

Specified by:
setValue in interface FieldAccessor<GraphBacked<org.neo4j.graphdb.PropertyContainer>>
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.

getValue

public final Object getValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)
Specified by:
getValue in interface FieldAccessor<GraphBacked<org.neo4j.graphdb.PropertyContainer>>
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.

doGetValue

protected Object doGetValue(GraphBacked<org.neo4j.graphdb.PropertyContainer> graphBacked)

Spring Data Graph

Copyright © 2011 SpringSource. All Rights Reserved.