UML

org.topcased.modeler.uml.sequencediagram.anchors
Class SequenceDiagramAnchor

java.lang.Object
  extended by org.eclipse.draw2d.ConnectionAnchorBase
      extended by org.eclipse.draw2d.AbstractConnectionAnchor
          extended by org.topcased.modeler.uml.sequencediagram.anchors.SequenceDiagramAnchor
All Implemented Interfaces:
org.eclipse.draw2d.AncestorListener, org.eclipse.draw2d.ConnectionAnchor

public class SequenceDiagramAnchor
extends org.eclipse.draw2d.AbstractConnectionAnchor

The anchor of the Sequence Diagram


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.eclipse.draw2d.AncestorListener
org.eclipse.draw2d.AncestorListener.Stub
 
Field Summary
 
Fields inherited from class org.eclipse.draw2d.ConnectionAnchorBase
listeners
 
Constructor Summary
SequenceDiagramAnchor(org.eclipse.draw2d.IFigure owner, org.eclipse.draw2d.geometry.Point pos)
          Contructor
SequenceDiagramAnchor(org.eclipse.draw2d.IFigure owner, org.eclipse.draw2d.geometry.Point cursor, org.eclipse.draw2d.geometry.Point oppositePos)
          Constructs a SequenceDiagramAnchor with the given owner figure.
 
Method Summary
protected  void computeRefPointFromCursor(org.eclipse.draw2d.geometry.Point pCursor, org.eclipse.draw2d.geometry.Point oppositePos)
          Compute the reference point
 boolean equals(java.lang.Object obj)
           
protected  org.eclipse.draw2d.geometry.Rectangle getBox()
          Returns the bounds of this LifelineAnchor's owner.
 org.eclipse.draw2d.geometry.Point getLocation(org.eclipse.draw2d.geometry.Point reference)
          The location is the reference point
 org.eclipse.draw2d.geometry.Point getReferencePoint()
          The reference point is the abolute position of the anchor
protected  SequenceDiagramFigure getSequenceDiagramFigure()
          Return the figure of the sequence diagram
 int hashCode()
           
 
Methods inherited from class org.eclipse.draw2d.AbstractConnectionAnchor
addAnchorListener, ancestorAdded, ancestorMoved, ancestorRemoved, getOwner, removeAnchorListener, setOwner
 
Methods inherited from class org.eclipse.draw2d.ConnectionAnchorBase
fireAnchorMoved
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SequenceDiagramAnchor

public SequenceDiagramAnchor(org.eclipse.draw2d.IFigure owner,
                             org.eclipse.draw2d.geometry.Point cursor,
                             org.eclipse.draw2d.geometry.Point oppositePos)
Constructs a SequenceDiagramAnchor with the given owner figure.

Parameters:
owner - The owner figure
cursor - the position of the cursor
oppositePos - the position of the opposite anchor

SequenceDiagramAnchor

public SequenceDiagramAnchor(org.eclipse.draw2d.IFigure owner,
                             org.eclipse.draw2d.geometry.Point pos)
Contructor

Parameters:
owner - the owner figure
pos - the position of the anchor
Method Detail

computeRefPointFromCursor

protected void computeRefPointFromCursor(org.eclipse.draw2d.geometry.Point pCursor,
                                         org.eclipse.draw2d.geometry.Point oppositePos)
Compute the reference point

Parameters:
pCursor - the position of the cursor
oppositePos - the position of the opposite anchor

getSequenceDiagramFigure

protected SequenceDiagramFigure getSequenceDiagramFigure()
Return the figure of the sequence diagram

Returns:
the figure of the sequence diagram

getLocation

public org.eclipse.draw2d.geometry.Point getLocation(org.eclipse.draw2d.geometry.Point reference)
The location is the reference point

See Also:
ConnectionAnchor.getLocation(org.eclipse.draw2d.geometry.Point)

getBox

protected org.eclipse.draw2d.geometry.Rectangle getBox()
Returns the bounds of this LifelineAnchor's owner. Subclasses can override this method to adjust the box the anchor can be placed on. For instance, the owner figure may have a drop shadow that should not be included in the box.

Returns:
The bounds of this LifelineAnchor's owner

getReferencePoint

public org.eclipse.draw2d.geometry.Point getReferencePoint()
The reference point is the abolute position of the anchor

Specified by:
getReferencePoint in interface org.eclipse.draw2d.ConnectionAnchor
Overrides:
getReferencePoint in class org.eclipse.draw2d.AbstractConnectionAnchor
See Also:
ConnectionAnchor.getReferencePoint()

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object
See Also:
Object.equals(java.lang.Object)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object
See Also:
Object.hashCode()

UML

Copyright (c) 2005 TOPCASED Contributors 2005 - 2007. All rights reserved.