org.spicefactory.pimento.intercept
Class CollectionUpdate

java.lang.Object
  extended by org.spicefactory.pimento.intercept.CollectionUpdate

public class CollectionUpdate
extends Object

Represents change set that will be applied to a persistent collection. Instances of this class may be returned by EntityUpdate instance which will not contain the complete modified collection but instead just the change set represented by instances of this class.

Author:
Jens Halm

Constructor Summary
CollectionUpdate(List<Object> addedElements, List<Object> removedElements)
          Creates a new instance.
 
Method Summary
 List<Object> getAddedElements()
          Returns the elements that will be added to the collection.
 List<Object> getRemovedElements()
          Returns the elements that will be removed from the collection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CollectionUpdate

public CollectionUpdate(List<Object> addedElements,
                        List<Object> removedElements)
Creates a new instance.

Parameters:
addedElements - elements that will be added to the collection
removedElements - elements that will be removed from the collection
Method Detail

getAddedElements

public List<Object> getAddedElements()
Returns the elements that will be added to the collection.

Returns:
the elements that will be added to the collection

getRemovedElements

public List<Object> getRemovedElements()
Returns the elements that will be removed from the collection.

Returns:
the elements that will be removed from the collection