com.agfa.hap.sdo.implementation
Class DataObjectList

java.lang.Object
  extended by java.util.AbstractCollection<E>
      extended by java.util.AbstractList<E>
          extended by java.util.ArrayList<AbstractDataObject>
              extended by com.agfa.hap.sdo.implementation.DataObjectList
All Implemented Interfaces:
IDataObjectList<AbstractDataObject>, java.io.Serializable, java.lang.Cloneable, java.lang.Iterable<AbstractDataObject>, java.util.Collection<AbstractDataObject>, java.util.List<AbstractDataObject>, java.util.RandomAccess

public class DataObjectList
extends java.util.ArrayList<AbstractDataObject>
implements IDataObjectList<AbstractDataObject>

List that performs AbstractDataObject bidirectional updates. If a dataobject is added/removed from this list, the opposite property of the dataobject is also set/reset. Also updates the containment relationship.

Author:
AMOCZ
See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.AbstractList
modCount
 
Constructor Summary
DataObjectList(AbstractDataObject owner, Property listProperty)
           
 
Method Summary
 boolean add(AbstractDataObject o)
           
 void add(int index, AbstractDataObject element)
           
 boolean addAll(java.util.Collection<? extends AbstractDataObject> c)
           
 boolean addAll(int index, java.util.Collection<? extends AbstractDataObject> c)
           
 void addForBidirectionalUpdate(AbstractDataObject o)
           
 void clear()
           
protected  void performBidirectionalUpdate(AbstractDataObject source, AbstractDataObject target)
           
 AbstractDataObject remove(int index)
           
 boolean remove(java.lang.Object o)
           
 void removeForBidirectionalUpdate(AbstractDataObject o)
           
 AbstractDataObject set(int index, AbstractDataObject element)
           
 
Methods inherited from class java.util.ArrayList
clone, contains, ensureCapacity, get, indexOf, isEmpty, lastIndexOf, removeRange, size, toArray, toArray, trimToSize
 
Methods inherited from class java.util.AbstractList
equals, hashCode, iterator, listIterator, listIterator, subList
 
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.List
contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, removeAll, retainAll, size, subList, toArray, toArray
 

Constructor Detail

DataObjectList

public DataObjectList(AbstractDataObject owner,
                      Property listProperty)
Method Detail

set

public AbstractDataObject set(int index,
                              AbstractDataObject element)
Specified by:
set in interface java.util.List<AbstractDataObject>
Overrides:
set in class java.util.ArrayList<AbstractDataObject>

removeForBidirectionalUpdate

public void removeForBidirectionalUpdate(AbstractDataObject o)
Specified by:
removeForBidirectionalUpdate in interface IDataObjectList<AbstractDataObject>

addForBidirectionalUpdate

public void addForBidirectionalUpdate(AbstractDataObject o)
Specified by:
addForBidirectionalUpdate in interface IDataObjectList<AbstractDataObject>

add

public boolean add(AbstractDataObject o)
Specified by:
add in interface java.util.Collection<AbstractDataObject>
Specified by:
add in interface java.util.List<AbstractDataObject>
Overrides:
add in class java.util.ArrayList<AbstractDataObject>

add

public void add(int index,
                AbstractDataObject element)
Specified by:
add in interface java.util.List<AbstractDataObject>
Overrides:
add in class java.util.ArrayList<AbstractDataObject>

remove

public AbstractDataObject remove(int index)
Specified by:
remove in interface java.util.List<AbstractDataObject>
Overrides:
remove in class java.util.ArrayList<AbstractDataObject>

remove

public boolean remove(java.lang.Object o)
Specified by:
remove in interface java.util.Collection<AbstractDataObject>
Specified by:
remove in interface java.util.List<AbstractDataObject>
Overrides:
remove in class java.util.ArrayList<AbstractDataObject>

performBidirectionalUpdate

protected void performBidirectionalUpdate(AbstractDataObject source,
                                          AbstractDataObject target)

clear

public void clear()
Specified by:
clear in interface java.util.Collection<AbstractDataObject>
Specified by:
clear in interface java.util.List<AbstractDataObject>
Overrides:
clear in class java.util.ArrayList<AbstractDataObject>

addAll

public boolean addAll(java.util.Collection<? extends AbstractDataObject> c)
Specified by:
addAll in interface java.util.Collection<AbstractDataObject>
Specified by:
addAll in interface java.util.List<AbstractDataObject>
Overrides:
addAll in class java.util.ArrayList<AbstractDataObject>

addAll

public boolean addAll(int index,
                      java.util.Collection<? extends AbstractDataObject> c)
Specified by:
addAll in interface java.util.List<AbstractDataObject>
Overrides:
addAll in class java.util.ArrayList<AbstractDataObject>


Copyright © 2007. All Rights Reserved.