Class AbstractOrientedAnchor
java.lang.Object
org.eclipse.draw2d.ConnectionAnchorBase
org.eclipse.draw2d.AbstractConnectionAnchor
org.eclipse.gmf.runtime.draw2d.ui.figures.BaseSlidableAnchor
org.eclipse.gmf.runtime.gef.ui.figures.SlidableAnchor
org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AlphaBasedSlidableImageAnchor
org.palladiosimulator.editors.sirius.custom.style.styleconfiguration.anchorprovider.AbstractOrientedAnchor
- All Implemented Interfaces:
org.eclipse.draw2d.AncestorListener
,org.eclipse.draw2d.ConnectionAnchor
,org.eclipse.gmf.runtime.draw2d.ui.figures.OrthogonalConnectionAnchor
public abstract class AbstractOrientedAnchor
extends org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AlphaBasedSlidableImageAnchor
An abstract anchor which calculates the location of its anchorPoint dependent of its figures
orientation.
The abstract method createTranslationCalculators() has to be implemented.
See
See
createTranslationCalculators()
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static interface
A translation inbetween rectangle bounds.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
ConstructorDescriptionAbstractOrientedAnchor
(org.eclipse.draw2d.IFigure f) AbstractOrientedAnchor
(org.eclipse.draw2d.IFigure f, org.eclipse.draw2d.geometry.PrecisionPoint p) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Map<Orientation,
AbstractOrientedAnchor.Translation> Implementation of mapping aAbstractOrientedAnchor.Translation
function to each orientation to translate a cursor position to a valid anchorPoint location.org.eclipse.draw2d.geometry.Point
getLocation
(org.eclipse.draw2d.geometry.Point reference) protected static Optional<Orientation>
getOrientation
(org.eclipse.draw2d.IFigure figure) Methods inherited from class org.eclipse.sirius.ext.gmf.runtime.gef.ui.figures.AlphaBasedSlidableImageAnchor
getContainer, getLocation, getLocation, getOrthogonalLocation
Methods inherited from class org.eclipse.gmf.runtime.gef.ui.figures.SlidableAnchor
getBox
Methods inherited from class org.eclipse.gmf.runtime.draw2d.ui.figures.BaseSlidableAnchor
equals, getAnchorRelativeLocation, getIntersectionPoints, getPolygonPoints, getReferencePoint, getTerminal, hashCode, isDefaultAnchor, normalizeToStraightlineTolerance, parseTerminalString
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
Methods inherited from interface org.eclipse.draw2d.ConnectionAnchor
addAnchorListener, getOwner, removeAnchorListener
-
Constructor Details
-
AbstractOrientedAnchor
public AbstractOrientedAnchor(org.eclipse.draw2d.IFigure f, org.eclipse.draw2d.geometry.PrecisionPoint p) -
AbstractOrientedAnchor
public AbstractOrientedAnchor(org.eclipse.draw2d.IFigure f)
-
-
Method Details
-
getLocation
public org.eclipse.draw2d.geometry.Point getLocation(org.eclipse.draw2d.geometry.Point reference) - Specified by:
getLocation
in interfaceorg.eclipse.draw2d.ConnectionAnchor
- Overrides:
getLocation
in classorg.eclipse.gmf.runtime.draw2d.ui.figures.BaseSlidableAnchor
-
createTranslationCalculators
protected abstract Map<Orientation,AbstractOrientedAnchor.Translation> createTranslationCalculators()Implementation of mapping aAbstractOrientedAnchor.Translation
function to each orientation to translate a cursor position to a valid anchorPoint location.
For an example implementation seeOperationRequiredRoleAnchorProvider
- Returns:
- the specified map
-
getOrientation
-