org.argouml.ui.targetmanager
Class TargetEvent

java.lang.Object
  extended by java.util.EventObject
      extended by org.argouml.ui.targetmanager.TargetEvent
All Implemented Interfaces:
java.io.Serializable

public class TargetEvent
extends java.util.EventObject

An event indicating that the target of ArgoUML has changed from the old set of Targets to the new set of Targets.

See Also:
Serialized Form

Field Summary
static java.lang.String TARGET_ADDED
          Indicates that a target is being added to the list of targets.
static java.lang.String TARGET_REMOVED
          Indicates that a target is being removed from the list of targets.
static java.lang.String TARGET_SET
          Indicates that a total new set of targets is set.
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
TargetEvent(java.lang.Object source, java.lang.String tEName, java.lang.Object[] oldTargets, java.lang.Object[] newTargets)
          Constructs a new TargetEvent.
 
Method Summary
 java.util.Collection getAddedTargetCollection()
          Returns the targets that are added to the selection.
 java.lang.Object[] getAddedTargets()
          Returns the targets that are added to the selection.
 java.lang.String getName()
          Getter for the name.
 java.lang.Object getNewTarget()
          Helper for getting the new target.
 java.lang.Object[] getNewTargets()
          Getter for the new targets.
 java.lang.Object[] getOldTargets()
          Getter for the old targets.
 java.util.Collection getRemovedTargetCollection()
          Gets the targets that are removed from the selection.
 java.lang.Object[] getRemovedTargets()
          Gets the targets that are removed from the selection.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TARGET_SET

public static final java.lang.String TARGET_SET
Indicates that a total new set of targets is set.

See Also:
Constant Field Values

TARGET_ADDED

public static final java.lang.String TARGET_ADDED
Indicates that a target is being added to the list of targets.

See Also:
Constant Field Values

TARGET_REMOVED

public static final java.lang.String TARGET_REMOVED
Indicates that a target is being removed from the list of targets.

See Also:
Constant Field Values
Constructor Detail

TargetEvent

public TargetEvent(java.lang.Object source,
                   java.lang.String tEName,
                   java.lang.Object[] oldTargets,
                   java.lang.Object[] newTargets)
Constructs a new TargetEvent.

Parameters:
source - The source that fired the TargetEvent, will always be the TargetManager
tEName - The name of the TargetEvent, can be TARGET_SET, TARGET_REMOVED or TARGET_ADDED
oldTargets - The old targets before the change took place
newTargets - The new targets after the change took place
Method Detail

getName

public java.lang.String getName()
Getter for the name.

Returns:
the name of the event

getOldTargets

public java.lang.Object[] getOldTargets()
Getter for the old targets.

Returns:
an object array with the old targets

getNewTargets

public java.lang.Object[] getNewTargets()
Getter for the new targets.

Returns:
an object array with the new targets

getNewTarget

public java.lang.Object getNewTarget()
Helper for getting the new target.

Returns:
the zero'th element in _newTargets, or null

getRemovedTargetCollection

public java.util.Collection getRemovedTargetCollection()
Gets the targets that are removed from the selection.

Returns:
the removed targets

getRemovedTargets

public java.lang.Object[] getRemovedTargets()
Gets the targets that are removed from the selection.

Returns:
the removed targets

getAddedTargetCollection

public java.util.Collection getAddedTargetCollection()
Returns the targets that are added to the selection.

Returns:
the added targets

getAddedTargets

public java.lang.Object[] getAddedTargets()
Returns the targets that are added to the selection.

Returns:
the added targets


ArgoUML © 1996-2006ArgoUML HomepageArgoUML Developers' pageArgoUML Cookbook