Spring Data Neo4j

org.springframework.data.neo4j.fieldaccess
Class ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor

java.lang.Object
  extended by org.springframework.data.neo4j.fieldaccess.RelatedToFieldAccessor
      extended by org.springframework.data.neo4j.fieldaccess.RelatedToCollectionFieldAccessorFactory.RelatedToCollectionFieldAccessor
          extended by org.springframework.data.neo4j.fieldaccess.ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor
All Implemented Interfaces:
FieldAccessor
Enclosing class:
ReadOnlyRelatedToCollectionFieldAccessorFactory

public static class ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor
extends RelatedToCollectionFieldAccessorFactory.RelatedToCollectionFieldAccessor


Field Summary
 
Fields inherited from class org.springframework.data.neo4j.fieldaccess.RelatedToFieldAccessor
direction, property, relatedType, relationshipHelper, template, type
 
Constructor Summary
ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor(org.neo4j.graphdb.RelationshipType type, org.neo4j.graphdb.Direction direction, Class<?> elementClass, Neo4jTemplate template, Neo4jPersistentProperty field)
           
 
Method Summary
 Object getDefaultValue()
          Returns a default implementation for a field or null if none is provided.
 boolean isWriteable(Object entity)
           
 Object setValue(Object entity, Object newVal, MappingPolicy mappingPolicy)
          handles field write modification.
 
Methods inherited from class org.springframework.data.neo4j.fieldaccess.RelatedToCollectionFieldAccessorFactory.RelatedToCollectionFieldAccessor
getValue
 
Methods inherited from class org.springframework.data.neo4j.fieldaccess.RelatedToFieldAccessor
checkAndGetNode, createAddedRelationships, createEntitySetFromRelationshipEndNodes, createManagedSet, createSetOfTargetNodes, removeMissingRelationships
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor

public ReadOnlyRelatedToCollectionFieldAccessorFactory.ReadOnlyRelatedToCollectionFieldAccessor(org.neo4j.graphdb.RelationshipType type,
                                                                                                org.neo4j.graphdb.Direction direction,
                                                                                                Class<?> elementClass,
                                                                                                Neo4jTemplate template,
                                                                                                Neo4jPersistentProperty field)
Method Detail

isWriteable

public boolean isWriteable(Object entity)
Specified by:
isWriteable in interface FieldAccessor
Overrides:
isWriteable in class RelatedToFieldAccessor
Returns:
false for read only or computed fields, true otherwise

setValue

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

Specified by:
setValue in interface FieldAccessor
Overrides:
setValue in class RelatedToCollectionFieldAccessorFactory.RelatedToCollectionFieldAccessor
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.

getDefaultValue

public Object getDefaultValue()
Description copied from interface: FieldAccessor
Returns a default implementation for a field or null if none is provided.

This default implementation is returned in detached mode by the DetachedEntityState when the value of the field is get.

Specified by:
getDefaultValue in interface FieldAccessor
Overrides:
getDefaultValue in class RelatedToCollectionFieldAccessorFactory.RelatedToCollectionFieldAccessor
Returns:
a default implementation for a field or null if none is provided.

Spring Data Neo4j

Copyright © 2012 SpringSource. All Rights Reserved.