org.argouml.uml.diagram.sequence.ui
Class FigSeqLink

java.lang.Object
  |
  +--FigEdgePoly
        |
        +--org.argouml.uml.diagram.ui.FigEdgeModelElement
              |
              +--org.argouml.uml.diagram.sequence.ui.FigSeqLink
All Implemented Interfaces:
ArgoEventListener, ArgoNotationEventListener, DelayedVChangeListener, java.util.EventListener, java.awt.event.KeyListener, java.awt.event.MouseListener, NotationContext, java.beans.PropertyChangeListener, java.beans.VetoableChangeListener

public class FigSeqLink
extends FigEdgeModelElement

See Also:
Serialized Form

Field Summary
protected  FigText _destMult
           
protected  FigText _destRole
           
protected  FigText _srcMult
           
protected  FigText _srcRole
           
static boolean SUPPRESS_BIDIRECTIONAL_ARROWS
           
 
Fields inherited from class org.argouml.uml.diagram.ui.FigEdgeModelElement
_name, _stereo, cat, ITALIC_LABEL_FONT, LABEL_FONT, MARGIN
 
Constructor Summary
FigSeqLink()
           
FigSeqLink(java.lang.Object edge)
           
 
Method Summary
 void addFigSeqStimulusWithAction()
          After a new link with a stimulus is added to the model and the figure of the link is created the figure of the stimulus has to be created and added to the layer
 java.util.Vector deletePathItems()
          Deletes all path-items of this FigSeqLink, returns all Owners of the deleted FigSeqStimuli.
 void dispose()
           
 java.util.Vector getContents()
          Get the Vector of all figures, that are shown in the diagram, is important because in sequence- diagrams often you have to update all figures
protected  java.lang.Object getDestination()
          Returns the destination of the edge.
 int getPortNumber(java.util.Vector contents)
          Returns the portNumber of this FigSeqLink.
protected  java.lang.Object getSource()
          Returns the source of the edge.
protected  void modelChanged(MElementEvent e)
          This is called aftern any part of the UML MModelElement has changed.
 void mouseClicked(java.awt.event.MouseEvent me)
          If the user double clicks on anu part of this FigNode, pass it down to one of the internal Figs.
 void mouseReleased(java.awt.event.MouseEvent me)
           
 java.lang.String ownerName()
           
 void removed(MElementEvent mee)
           
 void setActivations(FigSeqObject fso, FigSeqObject sourcePort, FigSeqObject destPort, int portNumber)
          Sets the activations for every FigSeqObject in this diagram.
 void setArrowHeads(MLink ml, java.util.Vector contents)
          Takes the action of this link and then set the aroow-heads on both ends of this FigSeqLink.
 void setDefaultAction()
          If the action of this Link cannot be set, this default action will be created and set
 void setOwner(java.lang.Object node)
           
protected  void textEdited(FigText ft)
          This method is called after the user finishes editing a text field that is in the FigEdgeModelElement.
 void updateActivations(FigSeqObject sourceObj, FigSeqObject destObj, FigRect sourceFig, FigRect destFig, java.util.Vector contents, int size, int portNumber)
          Updates the Vector _activations of all FigSeqObjects
protected  boolean updateClassifiers()
          Hack to let the sequence diagrams still do their job.
 void updatePorts(FigSeqObject sourceObj, FigSeqObject destObj, FigDynPort sourceFig, FigDynPort destFig, java.util.Vector contents, int size, int portNumber)
          Removes the port-figs of this FigSeqLink and updates the Vector _ports of all FigSeqObjects
 
Methods inherited from class org.argouml.uml.diagram.ui.FigEdgeModelElement
canEdit, damage, delayedVetoableChange, delete, finalize, getContextNotation, getItemUID, getNameFig, getPopUpActions, getSquaredDistance, getStereotypeFig, getTipString, hit, hitClarifier, keyPressed, keyReleased, keyTyped, listRoleItemSet, makeSelection, mouseEntered, mouseExited, mousePressed, notationAdded, notationChanged, notationProviderAdded, notationProviderRemoved, notationRemoved, paintClarifiers, postLoad, propertyChange, propertySet, recovered, renderingChanged, roleAdded, roleRemoved, setItemUID, updateStereotypeText, vetoableChange
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SUPPRESS_BIDIRECTIONAL_ARROWS

public static boolean SUPPRESS_BIDIRECTIONAL_ARROWS

_srcMult

protected FigText _srcMult

_srcRole

protected FigText _srcRole

_destMult

protected FigText _destMult

_destRole

protected FigText _destRole
Constructor Detail

FigSeqLink

public FigSeqLink()

FigSeqLink

public FigSeqLink(java.lang.Object edge)
Method Detail

ownerName

public java.lang.String ownerName()

setOwner

public void setOwner(java.lang.Object node)
Overrides:
setOwner in class FigEdgeModelElement

textEdited

protected void textEdited(FigText ft)
                   throws java.beans.PropertyVetoException
Description copied from class: FigEdgeModelElement
This method is called after the user finishes editing a text field that is in the FigEdgeModelElement. Determine which field and update the model. This class handles the name, subclasses should override to handle other text elements.

Overrides:
textEdited in class FigEdgeModelElement
java.beans.PropertyVetoException

modelChanged

protected void modelChanged(MElementEvent e)
Description copied from class: FigEdgeModelElement
This is called aftern any part of the UML MModelElement has changed. This method automatically updates the name FigText. Subclasses should override and update other parts.

Overrides:
modelChanged in class FigEdgeModelElement

setArrowHeads

public void setArrowHeads(MLink ml,
                          java.util.Vector contents)
Takes the action of this link and then set the aroow-heads on both ends of this FigSeqLink.


addFigSeqStimulusWithAction

public void addFigSeqStimulusWithAction()
After a new link with a stimulus is added to the model and the figure of the link is created the figure of the stimulus has to be created and added to the layer


setActivations

public void setActivations(FigSeqObject fso,
                           FigSeqObject sourcePort,
                           FigSeqObject destPort,
                           int portNumber)
Sets the activations for every FigSeqObject in this diagram. Every object must update its activations, when a FigSeqLink is moved into position.


getPortNumber

public int getPortNumber(java.util.Vector contents)
Returns the portNumber of this FigSeqLink. The first FigSeqLink in the diagram has the number one.


getContents

public java.util.Vector getContents()
Get the Vector of all figures, that are shown in the diagram, is important because in sequence- diagrams often you have to update all figures


deletePathItems

public java.util.Vector deletePathItems()
Deletes all path-items of this FigSeqLink, returns all Owners of the deleted FigSeqStimuli.


updatePorts

public void updatePorts(FigSeqObject sourceObj,
                        FigSeqObject destObj,
                        FigDynPort sourceFig,
                        FigDynPort destFig,
                        java.util.Vector contents,
                        int size,
                        int portNumber)
Removes the port-figs of this FigSeqLink and updates the Vector _ports of all FigSeqObjects


updateActivations

public void updateActivations(FigSeqObject sourceObj,
                              FigSeqObject destObj,
                              FigRect sourceFig,
                              FigRect destFig,
                              java.util.Vector contents,
                              int size,
                              int portNumber)
Updates the Vector _activations of all FigSeqObjects


setDefaultAction

public void setDefaultAction()
If the action of this Link cannot be set, this default action will be created and set


dispose

public void dispose()
Overrides:
dispose in class FigEdgeModelElement
See Also:
org.tigris.gef.presentation.Fig#dispose()

mouseClicked

public void mouseClicked(java.awt.event.MouseEvent me)
Description copied from class: FigEdgeModelElement
If the user double clicks on anu part of this FigNode, pass it down to one of the internal Figs. This allows the user to initiate direct text editing.

Specified by:
mouseClicked in interface java.awt.event.MouseListener
Overrides:
mouseClicked in class FigEdgeModelElement

mouseReleased

public void mouseReleased(java.awt.event.MouseEvent me)
Specified by:
mouseReleased in interface java.awt.event.MouseListener
Overrides:
mouseReleased in class FigEdgeModelElement

removed

public void removed(MElementEvent mee)
Overrides:
removed in class FigEdgeModelElement

getDestination

protected java.lang.Object getDestination()
Description copied from class: FigEdgeModelElement
Returns the destination of the edge. The destination is the owner of the node the edge travels to in a binary relationship. For instance: for a classifierrole, this is the receiver. Since we don't support n-array associations but only binary relations, source/destination works for all edges.

Overrides:
getDestination in class FigEdgeModelElement
Returns:
Object
See Also:
FigEdgeModelElement.getDestination()

getSource

protected java.lang.Object getSource()
Description copied from class: FigEdgeModelElement
Returns the source of the edge. The source is the owner of the node the edge travels from in a binary relationship. For instance: for a classifierrole, this is the sender.

Overrides:
getSource in class FigEdgeModelElement
Returns:
MModelElement
See Also:
FigEdgeModelElement.getSource()

updateClassifiers

protected boolean updateClassifiers()
Hack to let the sequence diagrams still do their job. The sequence diagrams do not update their model correctly and that's why the updating of the classifiers goes wrong.

Overrides:
updateClassifiers in class FigEdgeModelElement
Returns:
boolean whether or not the update was sucessful
See Also:
FigEdgeModelElement.updateClassifiers()


ArgoUML © 1996-2003 (20040229)ArgoUML Project HomeArgoUML Cookbook