|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectCH.ifa.draw.standard.AbstractFigure
org.openbp.cockpit.modeler.figures.process.LineFigure
public abstract class LineFigure
Abstract line figure.
| Field Summary | |
|---|---|
protected int |
xPos
Position of the line (x coordinate) |
protected int |
yPos
Position of the line (y coordinate) |
| Fields inherited from interface org.openbp.cockpit.modeler.figures.VisualElement |
|---|
VISUAL_DISPLAY_ALL, VISUAL_DND_PARTICIPANT, VISUAL_VISIBLE |
| Fields inherited from interface CH.ifa.draw.framework.Figure |
|---|
POPUP_MENU |
| Constructor Summary | |
|---|---|
LineFigure(ProcessDrawing drawing)
Default constructor. |
|
| Method Summary | |
|---|---|
void |
basicDisplayBox(java.awt.Point origin,
java.awt.Point corner)
|
protected void |
basicMoveBy(int x,
int y)
|
boolean |
containsPoint(int x,
int y)
|
void |
decodeGeometry(java.lang.String geometry)
Decodes enclosed geometry information. |
java.awt.Rectangle |
displayBox()
|
void |
dragActionTriggered(java.lang.Object regionId,
java.awt.Point p)
Called to signal additional actions, such as hovering for a certain time over the region. |
void |
dragEnded(java.awt.datatransfer.Transferable transferable)
called when a dragging has ended. |
void |
dragStarted(java.awt.datatransfer.Transferable transferable)
Called when a dragging has been started. |
void |
draw(java.awt.Graphics g)
Draws the figure in the given graphics. |
java.lang.String |
encodeGeometry()
Encodes the figure geometry in a string. |
VisualElement |
findVisualElement(int x,
int y)
Gets the visual element that is a child of this element and matches the given coordinates. |
VisualElement |
findVisualElementInside(int x,
int y)
Gets the visual element that is a child of this element and matches the given coordinates (recursively). |
java.util.List |
getAllDropRegions(java.util.List flavors,
java.awt.datatransfer.Transferable data,
java.awt.event.MouseEvent mouseEvent)
Returns a list of all regions of this client AND possible sub clients. |
java.util.List |
getAllImportersAt(java.awt.Point p)
Returns all importers which will be accepted at the given point by this client or one of its sub clients. |
java.awt.Color |
getColor()
Gets the color. |
ProcessDrawing |
getDrawing()
Gets the drawing the element is a part of. |
java.util.List |
getDropRegions(java.util.List flavors,
java.awt.datatransfer.Transferable data,
java.awt.event.MouseEvent mouseEvent)
Returns a list of drop regions of this client that are compatible with the provided data flavors. |
java.util.List |
getImportersAt(java.awt.Point p)
Returns all importers which will be accepted at the given point by this client. |
VisualElement |
getParentElement()
Gets parent element of this element, if any. |
CH.ifa.draw.framework.Figure |
getPresentationFigure()
Gets the presentation figure of this element. |
java.awt.Stroke |
getStroke()
Gets the stroke. |
java.util.List |
getSubClients()
Returns subordinate clients of this client. |
boolean |
handleEvent(VisualElementEvent event)
Handler method that is called for handling events. |
java.util.Vector |
handles()
We display a single font size handle in the top left corner only. |
boolean |
importData(java.lang.Object regionId,
java.awt.datatransfer.Transferable data,
java.awt.Point p)
Imports the given transferable into the given region. |
java.awt.Rectangle |
infiniteDisplayBox()
Returns the display box of the figure that extends until infinity (or at least up to a very high value). |
void |
invalidate()
|
boolean |
isVerticalLine()
Gets the vertical line. |
boolean |
isVisible()
Gets the flag if the element is currently visible. |
void |
setColor(java.awt.Color color)
Sets the color. |
void |
setDrawing(ProcessDrawing drawing)
Sets the drawing the element is a part of. |
void |
setStroke(java.awt.Stroke stroke)
Sets the stroke. |
void |
setVerticalLine(boolean verticalLine)
Sets the vertical line. |
void |
setVisible(boolean visible)
Sets the flag if the element is currently visible. |
void |
updatePresentationFigure()
Updates (reinitializes) the presentation figure. |
| Methods inherited from class CH.ifa.draw.standard.AbstractFigure |
|---|
addFigureChangeListener, addToContainer, canConnect, center, changed, clone, connectedTextLocator, connectionInsets, connectorAt, connectorVisibility, decompose, displayBox, displayBox, figures, findFigureInside, getAttribute, getZValue, includes, isEmpty, listener, moveBy, read, release, removeFigureChangeListener, removeFromContainer, setAttribute, setZValue, size, willChange, write |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface CH.ifa.draw.framework.Figure |
|---|
addFigureChangeListener, addToContainer, canConnect, center, changed, clone, connectedTextLocator, connectionInsets, connectorAt, connectorVisibility, decompose, displayBox, displayBox, figures, findFigureInside, getAttribute, getZValue, includes, isEmpty, listener, moveBy, release, removeFigureChangeListener, removeFromContainer, setAttribute, setZValue, size, willChange |
| Methods inherited from interface CH.ifa.draw.util.Storable |
|---|
read, write |
| Field Detail |
|---|
protected int xPos
protected int yPos
| Constructor Detail |
|---|
public LineFigure(ProcessDrawing drawing)
drawing - Process drawing we belong to| Method Detail |
|---|
public boolean isVerticalLine()
public void setVerticalLine(boolean verticalLine)
public java.awt.Stroke getStroke()
public void setStroke(java.awt.Stroke stroke)
public java.awt.Color getColor()
public void setColor(java.awt.Color color)
public java.util.Vector handles()
handles in interface CH.ifa.draw.framework.Figurehandles in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.handles()
public void basicDisplayBox(java.awt.Point origin,
java.awt.Point corner)
basicDisplayBox in interface CH.ifa.draw.framework.FigurebasicDisplayBox in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.basicDisplayBox(Point origin, Point corner)public java.awt.Rectangle displayBox()
displayBox in interface CH.ifa.draw.framework.FiguredisplayBox in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.displayBox()public void invalidate()
invalidate in interface CH.ifa.draw.framework.Figureinvalidate in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.invalidate()
protected void basicMoveBy(int x,
int y)
basicMoveBy in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.basicMoveBy(int x, int y)public java.awt.Rectangle infiniteDisplayBox()
public boolean containsPoint(int x,
int y)
containsPoint in interface CH.ifa.draw.framework.FigurecontainsPoint in class CH.ifa.draw.standard.AbstractFigureAbstractFigure.containsPoint(int, int)public void draw(java.awt.Graphics g)
draw in interface CH.ifa.draw.framework.Figuredraw in class CH.ifa.draw.standard.AbstractFigureg - Graphics to draw toAbstractFigure.draw(Graphics g)public void decodeGeometry(java.lang.String geometry)
geometry - Geometry string to decode or nullpublic java.lang.String encodeGeometry()
public void setDrawing(ProcessDrawing drawing)
VisualElement
setDrawing in interface VisualElementVisualElement.setDrawing(ProcessDrawing)public ProcessDrawing getDrawing()
VisualElement
getDrawing in interface VisualElementVisualElement.getDrawing()public VisualElement getParentElement()
VisualElement
getParentElement in interface VisualElementVisualElement.getParentElement()public CH.ifa.draw.framework.Figure getPresentationFigure()
VisualElement
getPresentationFigure in interface VisualElementVisualElement.getPresentationFigure()public void updatePresentationFigure()
VisualElement
updatePresentationFigure in interface VisualElementVisualElement.updatePresentationFigure()public boolean isVisible()
VisualElement
isVisible in interface VisualElementVisualElement.isVisible()public void setVisible(boolean visible)
VisualElement
setVisible in interface VisualElementVisualElement.setVisible(boolean)public boolean handleEvent(VisualElementEvent event)
VisualElement
handleEvent in interface VisualElementevent - Event that desribes the event
VisualElement.handleEvent(VisualElementEvent event)
public VisualElement findVisualElement(int x,
int y)
VisualElement
findVisualElement in interface VisualElementx - World coordinates of the point to searchy - World coordinates of the point to search
VisualElement.findVisualElement(int, int)
public VisualElement findVisualElementInside(int x,
int y)
VisualElement
findVisualElementInside in interface VisualElementx - World coordinates of the point to searchy - World coordinates of the point to search
VisualElement.findVisualElementInside(int, int)
public void dragActionTriggered(java.lang.Object regionId,
java.awt.Point p)
InteractionClient
dragActionTriggered in interface InteractionClientregionId - Id of the region to import into (see BasicDropRegion.getId)p - Current mouse position in screen coordinatesInteractionClient.dragActionTriggered(Object, Point)public void dragEnded(java.awt.datatransfer.Transferable transferable)
InteractionClient
dragEnded in interface InteractionClienttransferable - Transferable that has been draggedInteractionClient.dragEnded(Transferable)public void dragStarted(java.awt.datatransfer.Transferable transferable)
InteractionClient
dragStarted in interface InteractionClienttransferable - Transferable to be draggedInteractionClient.dragStarted(Transferable)
public java.util.List getAllDropRegions(java.util.List flavors,
java.awt.datatransfer.Transferable data,
java.awt.event.MouseEvent mouseEvent)
InteractionClient
getAllDropRegions in interface InteractionClientflavors - List of data flavors to checkdata - Transferable to importmouseEvent - Mouse event that initiated the drag action
DragAwareRegion object or null if the drop client
or one of its sub clients cannot satisfy at least one of the supplied data flavorsInteractionClient.getAllDropRegions(List, Transferable, MouseEvent)
public java.util.List getDropRegions(java.util.List flavors,
java.awt.datatransfer.Transferable data,
java.awt.event.MouseEvent mouseEvent)
InteractionClient
getDropRegions in interface InteractionClientflavors - List of data flavors to checkdata - Transferable to be importedmouseEvent - Mouse event that initiated the drag action
DragAwareRegion object or null if the drop client
cannot satisfy at least one of the supplied data flavors.InteractionClient.getDropRegions(List, Transferable, MouseEvent)public java.util.List getImportersAt(java.awt.Point p)
InteractionClient
getImportersAt in interface InteractionClientp - Current mouse position in screen coordinates
Importer objects or nullInteractionClient.getImportersAt(Point)public java.util.List getAllImportersAt(java.awt.Point p)
InteractionClient
getAllImportersAt in interface InteractionClientp - Current mouse position in screen coordinates
Importer objects or nullInteractionClient.getAllImportersAt(Point)public java.util.List getSubClients()
InteractionClient
getSubClients in interface InteractionClientInteractionClient objects or null if this drop client doesn't have sub drop clientsInteractionClient.getSubClients()
public boolean importData(java.lang.Object regionId,
java.awt.datatransfer.Transferable data,
java.awt.Point p)
InteractionClient
importData in interface InteractionClientregionId - Id of the region to import into (see BasicDropRegion.getId)data - Transferable to importp - Drop point in glass coordinates
InteractionClient.importData(Object, Transferable, Point)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||