kaapo.projectmanager
Class Selection
java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractList<E>
java.util.Vector<DiagramComponentWrapper>
kaapo.projectmanager.Selection
- All Implemented Interfaces:
- Serializable, Cloneable, Iterable<DiagramComponentWrapper>, Collection<DiagramComponentWrapper>, List<DiagramComponentWrapper>, RandomAccess
public class Selection
- extends Vector<DiagramComponentWrapper>
A Selection keeps track of the selected DiagramComponentWrappers.
- Author:
- hprajani, iheikkin
- See Also:
- Serialized Form
Methods inherited from class java.util.Vector |
add, addAll, addAll, addElement, capacity, clear, clone, contains, containsAll, copyInto, elementAt, elements, ensureCapacity, equals, firstElement, get, hashCode, indexOf, indexOf, insertElementAt, isEmpty, lastElement, lastIndexOf, lastIndexOf, remove, remove, removeAll, removeAllElements, removeElement, removeElementAt, removeRange, retainAll, set, setElementAt, setSize, size, subList, toArray, toArray, toString, trimToSize |
Selection
public Selection()
- Constructs an empty Selection.
Selection
public Selection(DiagramComponentWrapper diagramcomponent)
throws NullPointerException
- Constructs a Selection with only one selected DiagramComponent.
- Parameters:
diagramcomponent
- the current selected DiagramComponent
- Throws:
NullPointerException
Selection
public Selection(DiagramComponentWrapper[] diagramcomponents)
throws NullPointerException
- Constructs a Selection with multiple selected DiagramComponents.
- Parameters:
diagramcomponents
-
- Throws:
NullPointerException
Selection
public Selection(List<DiagramComponentWrapper> diagramcomponents)
throws NullPointerException
- Constructs a Selection with multiple selected DiagramComponents.
- Parameters:
diagramcomponents
-
- Throws:
NullPointerException
add
public boolean add(DiagramComponentWrapper dcw)
throws NullPointerException
- Adds the given wrapper to the selection.
- Specified by:
add
in interface Collection<DiagramComponentWrapper>
- Specified by:
add
in interface List<DiagramComponentWrapper>
- Overrides:
add
in class Vector<DiagramComponentWrapper>
- Parameters:
dcw
- The wrapper to be added to the selection.
- Returns:
- Returns true if the wrapper could be added.
- Throws:
NullPointerException