org.apache.jdo.sco
Interface SCOCollection

All Superinterfaces:
java.util.Collection, SCO
All Known Implementing Classes:
ArrayList, HashSet, LinkedList, TreeSet, Vector

public interface SCOCollection
extends java.util.Collection, SCO


Method Summary
 void addAllInternal(java.util.Collection c)
          Adds objects of the given Collection to this Collection without recording the event.
 void addInternal(java.lang.Object o)
          Adds object to the Collection without recording the event.
 boolean allowNulls()
          Returns whether nulls are permitted as elements.
 void clearInternal()
          Clears Collection without recording the event.
 java.util.Iterator eitherIterator()
          Get an iterator regardless of whether the map is frozen.
 java.util.Iterator frozenIterator()
          Get an iterator over the frozen elements of this collection.
 java.util.Collection getAdded()
          Returns the Collection of added elements
 java.lang.Class getElementType()
          Returns the element type assignment compatible with all added elements of this collection.
 java.util.Collection getRemoved()
          Returns the Collection of removed elements
 void removeInternal(java.lang.Object o)
          Removes element from the Collection without recording the event.
 void reset()
          Resets removed and added lists after flush
 void setFrozen(java.lang.Object[] elements)
          Set the contents of this Collection from the frozen elements.
 
Methods inherited from interface java.util.Collection
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 
Methods inherited from interface org.apache.jdo.sco.SCO
clone, getFieldName, getOwner, setOwner, unsetOwner
 

Method Detail

reset

public void reset()
Resets removed and added lists after flush


addInternal

public void addInternal(java.lang.Object o)
Adds object to the Collection without recording the event. Used internaly to initially populate the Collection


addAllInternal

public void addAllInternal(java.util.Collection c)
Adds objects of the given Collection to this Collection without recording the event. Used internaly to initially populate the Collection


clearInternal

public void clearInternal()
Clears Collection without recording the event. Used internaly to clear the Collection


removeInternal

public void removeInternal(java.lang.Object o)
Removes element from the Collection without recording the event. Used internaly to update the Collection


getAdded

public java.util.Collection getAdded()
Returns the Collection of added elements

Returns:
Collection of the added elements as java.util.Collection

getRemoved

public java.util.Collection getRemoved()
Returns the Collection of removed elements

Returns:
Collection of the removed elements as java.util.Collection

getElementType

public java.lang.Class getElementType()
Returns the element type assignment compatible with all added elements of this collection.

Returns:
the element type assignment compatible with all added elements.

allowNulls

public boolean allowNulls()
Returns whether nulls are permitted as elements.

Returns:
true if nulls are permitted as elements.

setFrozen

public void setFrozen(java.lang.Object[] elements)
Set the contents of this Collection from the frozen elements.

Parameters:
elements - the frozen elements.
Since:
1.0.1

frozenIterator

public java.util.Iterator frozenIterator()
Get an iterator over the frozen elements of this collection. This allows iterator of the elements without thawing them, as is needed for transcription.

Returns:
an iterator over the frozen elements.
Since:
1.0.1

eitherIterator

public java.util.Iterator eitherIterator()
Get an iterator regardless of whether the map is frozen. If frozen, get a frozen iterator. If thawed, get a regular iterator.

Returns:
the iterator over the elements.
Since:
1.0.1