Interface COM.ibm.jaws.mofw.ReferenceCollection
All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface COM.ibm.jaws.mofw.ReferenceCollection

public interface ReferenceCollection
extends Object
extends QueryableCollection
The Reference Collection (ReferenceCollection) is a Collection that manages references to other objects. The implication is that the object must have been located through some prior call (to a KeyedCollection, NamedCollection, BaseCollection, Stream or another ReferenceCollection).

RCs are used whenever "bag" like behavior is desired. In OOD terms, select an RC whenever a multiple cardinality by reference relationship exists between classes.

For example, if a given "leg" of a Trip can have any references to number of Reservations, then use an ReferenceCollection. If it needed to have the Reservations "by value" then use a BaseCollection. If it needs to "qualify" them with a name, then use a NamedCollection.


Method Index

 o insertElement(Object)
Use this method to insert the element at an unspecified position in the collection.
 o removeElement(Object)
Use this method to remove all references to the object in the collection.

Methods

 o insertElement
  public abstract boolean insertElement(Object element)
Use this method to insert the element at an unspecified position in the collection. Duplicate references to the same object can exist.
Parameters:
element - the object to insert into the collection.
Returns:
a boolean that indicates if the insert was successful or not. Catastrophic reasons for why the insert failed should be indicated through a runtime exception or error (and documented by the implementor).
 o removeElement
  public abstract void removeElement(Object element)
Use this method to remove all references to the object in the collection.
Parameters:
element - the object to remove from the collection.

All Packages  Class Hierarchy  This Package  Previous  Next  Index