Package org.eclipse.draw2d
Class AbstractConnectionAnchor
java.lang.Object
org.eclipse.draw2d.ConnectionAnchorBase
org.eclipse.draw2d.AbstractConnectionAnchor
- All Implemented Interfaces:
- AncestorListener,- ConnectionAnchor
- Direct Known Subclasses:
- ChopboxAnchor,- EllipseAnchor
public abstract class AbstractConnectionAnchor
extends ConnectionAnchorBase
implements AncestorListener
Provides support for anchors which depend on a figure for thier location.
- 
Nested Class SummaryNested classes/interfaces inherited from interface org.eclipse.draw2d.AncestorListenerAncestorListener.Stub
- 
Field SummaryFields inherited from class org.eclipse.draw2d.ConnectionAnchorBaselisteners
- 
Constructor SummaryConstructorsConstructorDescriptionConstructs an AbstractConnectionAnchor with no owner.AbstractConnectionAnchor(IFigure owner) Constructs an AbstractConnectionAnchor with the owner supplied as input.
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddAnchorListener(AnchorListener listener) Adds the given listener to the listeners to be notified of anchor location changes.voidancestorAdded(IFigure ancestor) Called when an ancestor has been added into the listening figure's hierarchy.voidancestorMoved(IFigure figure) Notifies all the listeners of this anchor's location change.voidancestorRemoved(IFigure ancestor) Called when an ancestor has been removed from the listening figure's hierarchy.getOwner()Returns the owner Figure on which this anchor's location is dependent.Returns the point which is used as the reference by this AbstractConnectionAnchor.voidremoveAnchorListener(AnchorListener listener) Removes the given listener from this anchor.voidSets the owner of this anchor, on whom this anchors location is dependent.Methods inherited from class org.eclipse.draw2d.ConnectionAnchorBasefireAnchorMovedMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.draw2d.ConnectionAnchorgetLocation
- 
Constructor Details- 
AbstractConnectionAnchorpublic AbstractConnectionAnchor()Constructs an AbstractConnectionAnchor with no owner.- Since:
- 2.0
 
- 
AbstractConnectionAnchorConstructs an AbstractConnectionAnchor with the owner supplied as input.- Parameters:
- owner- Owner of this anchor
- Since:
- 2.0
 
 
- 
- 
Method Details- 
addAnchorListenerAdds the given listener to the listeners to be notified of anchor location changes.- Specified by:
- addAnchorListenerin interface- ConnectionAnchor
- Overrides:
- addAnchorListenerin class- ConnectionAnchorBase
- Parameters:
- listener- Listener to be added
- Since:
- 2.0
- See Also:
 
- 
ancestorMovedNotifies all the listeners of this anchor's location change.- Specified by:
- ancestorMovedin interface- AncestorListener
- Parameters:
- figure- Anchor-owning Figure which has moved
- Since:
- 2.0
- See Also:
 
- 
ancestorAddedDescription copied from interface:AncestorListenerCalled when an ancestor has been added into the listening figure's hierarchy.- Specified by:
- ancestorAddedin interface- AncestorListener
- Parameters:
- ancestor- The ancestor that was added
- See Also:
 
- 
ancestorRemovedDescription copied from interface:AncestorListenerCalled when an ancestor has been removed from the listening figure's hierarchy.- Specified by:
- ancestorRemovedin interface- AncestorListener
- Parameters:
- ancestor- The ancestor that has been removed
- See Also:
 
- 
getOwnerReturns the owner Figure on which this anchor's location is dependent.- Specified by:
- getOwnerin interface- ConnectionAnchor
- Returns:
- Owner of this anchor
- Since:
- 2.0
- See Also:
 
- 
getReferencePointReturns the point which is used as the reference by this AbstractConnectionAnchor. It is generally dependent on the Figure which is the owner of this AbstractConnectionAnchor.- Specified by:
- getReferencePointin interface- ConnectionAnchor
- Returns:
- The reference point of this anchor
- Since:
- 2.0
- See Also:
 
- 
removeAnchorListenerRemoves the given listener from this anchor. If all the listeners are removed, then this anchor removes itself from its owner.- Specified by:
- removeAnchorListenerin interface- ConnectionAnchor
- Overrides:
- removeAnchorListenerin class- ConnectionAnchorBase
- Parameters:
- listener- Listener to be removed from this anchors listeners list
- Since:
- 2.0
- See Also:
 
- 
setOwnerSets the owner of this anchor, on whom this anchors location is dependent.- Parameters:
- owner- Owner of this anchor
- Since:
- 2.0
 
 
-