Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.cayenne.access
Class ToManyList

    java.lang.Object
      org.apache.cayenne.util.RelationshipFault
          org.apache.cayenne.util.PersistentObjectList
              org.apache.cayenne.access.ToManyList

All Implemented Interfaces:
  java.io.Serializable, java.lang.Iterable, java.util.Collection, java.util.List, PersistentObjectCollection, ValueHolder

    public class ToManyList

extends PersistentObjectList
implements java.io.Serializable

A list that holds objects for to-many relationships. All operations, except for resolving the list from DB, are not synchronized. The safest way to implement custom synchronization is to synchronize on parent ObjectStore.

See Also:
  Serialized Form

Field Summary

Fields inherited from class org.apache.cayenne.util.PersistentObjectList
`addedToUnresolved, objectList, removedFromUnresolved`

Fields inherited from class org.apache.cayenne.util.RelationshipFault
`relationshipName, relationshipOwner`

Constructor Summary
`ToManyList(Persistent source, java.lang.String relationship)` Creates ToManyList.

Method Summary
`int` | `hashCode()`
`protected void` | `postprocessAdd(java.util.Collection collection)`
`protected void` | `postprocessAdd(java.lang.Object addedObject)`
`protected void` | `postprocessRemove(java.util.Collection collection)`
`protected void` | `postprocessRemove(java.lang.Object removedObject)`
`protected boolean` | `shouldAddToRemovedFromUnresolvedList(java.lang.Object object)`
`java.lang.String` | `toString()`
`protected void` | `updateReverse(java.util.List resolved)`

Methods inherited from class org.apache.cayenne.util.PersistentObjectList
`add, add, addAll, addAll, addDirectly, addLocal, clear, clearLocalChanges, contains, containsAll, equals, get, getValue, getValueDirectly, indexOf, invalidate, isEmpty, isFault, iterator, lastIndexOf, listIterator, listIterator, mergeLocalChanges, remove, remove, removeAll, removeDirectly, removeLocal, resolvedObjectList, retainAll, set, setObjectList, setValue, setValueDirectly, size, subList, toArray, toArray`

Methods inherited from class org.apache.cayenne.util.RelationshipFault
`getRelationshipName, getRelationshipOwner, isTransientParent, isUncommittedParent, resolveFromDB`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### ToManyList

    public ToManyList(Persistent source,
                      java.lang.String relationship)

  Creates ToManyList.

  Since:
    1.1

Method Detail

### hashCode

    public int hashCode()

  Specified by:
    `hashCode` in interface `java.util.Collection`
  Specified by:
    `hashCode` in interface `java.util.List`
  Overrides:
    `hashCode` in class `PersistentObjectList`

### shouldAddToRemovedFromUnresolvedList

    protected boolean shouldAddToRemovedFromUnresolvedList(java.lang.Object object)

  Overrides:
    `shouldAddToRemovedFromUnresolvedList` in class `PersistentObjectList`
  Returns:
    whether object should be added to `PersistentObjectList.removedFromUnresolved` during removal

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `PersistentObjectList`

### postprocessAdd

    protected void postprocessAdd(java.util.Collection collection)

  Overrides:
    `postprocessAdd` in class `PersistentObjectList`

### postprocessRemove

    protected void postprocessRemove(java.util.Collection collection)

  Overrides:
    `postprocessRemove` in class `PersistentObjectList`

### postprocessAdd

    protected void postprocessAdd(java.lang.Object addedObject)

  Overrides:
    `postprocessAdd` in class `PersistentObjectList`

### postprocessRemove

    protected void postprocessRemove(java.lang.Object removedObject)

  Overrides:
    `postprocessRemove` in class `PersistentObjectList`

### updateReverse

    protected void updateReverse(java.util.List resolved)

  Overrides:
    `updateReverse` in class `RelationshipFault`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2012 Apache Cayenne. All Rights Reserved.