public class TableConnectionPoint extends ConnectionPoint
node| Constructor and Description |
|---|
TableConnectionPoint() |
TableConnectionPoint(TableNode table,
DiagramLink link,
boolean incoming,
int row) |
| Modifier and Type | Method and Description |
|---|---|
void |
addLinkToNode()
Adds the link associated with this connection point to the associated node.
|
boolean |
calculateIntersections()
Determines whether the end of a link should be aligned to the point where the node
contour is intersected by the line connecting the centers of the connected nodes.
|
android.graphics.PointF |
getAnchorPos(int anchorIdx)
Returns the point from the node's associated anchor pattern
(if any) with the specified index or the link's initial point.
|
boolean |
getAnchorPos(int anchorIdx,
android.graphics.PointF point)
Returns the point from the node's associated anchor pattern
(if any) with the specified index.
|
android.graphics.PointF |
getEndPoint()
Calculates the coordinates of the this connection point expressed in document coordinates.
|
android.graphics.PointF |
getInitialPoint()
Returns a point (usually the center of the bounding rectangle) contained within the associated node.
|
android.graphics.PointF |
getIntersection(android.graphics.PointF pt1,
android.graphics.PointF pt2)
Calculates the intersection point between the specified line segment and
the contour of the node associated with this connection point.
|
int |
getRow()
Gets the index of a constituent item within the associated node where the
link represented by this connection point is connected, or -1, if the link is
connected to the node itself.
|
TableNode |
getTable() |
boolean |
linkChanges(DiagramNode node,
android.graphics.PointF point)
Checks whether the relationship represented by the associated link would change
if the link is attached to the specified node at the specified point.
|
void |
readExternal(java.io.ObjectInput in)
Deserializes the connection point data.
|
void |
removeLinkFromNode()
Removes the link associated with this connection point from the associated node.
|
boolean |
sameNode(ConnectionPoint otherConnectionPoint)
Checks whether the current connection point and the specified
connection point are associated with the same node.
|
void |
saveEndRelative()
Updates the coordinates of the connection point represented by this
link, relative to the bounding rectangle of the associated node.
|
protected void |
updateFromPoint(android.graphics.PointF point)
Updates the connection state according to the specified point,
without changing the related node.
|
void |
writeExternal(java.io.ObjectOutput out)
Serializes the connection point data.
|
canMoveLink, getIncoming, getLink, getNode, getNodeRect, getRelativePosition, nodesIntersect, setRelativePositionpublic TableConnectionPoint(TableNode table, DiagramLink link, boolean incoming, int row)
public TableConnectionPoint()
public int getRow()
ConnectionPointgetRow in class ConnectionPointpublic TableNode getTable()
public boolean linkChanges(DiagramNode node, android.graphics.PointF point)
ConnectionPointlinkChanges in class ConnectionPointprotected void updateFromPoint(android.graphics.PointF point)
ConnectionPointupdateFromPoint in class ConnectionPointpublic boolean sameNode(ConnectionPoint otherConnectionPoint)
ConnectionPointsameNode in class ConnectionPointpublic android.graphics.PointF getIntersection(android.graphics.PointF pt1,
android.graphics.PointF pt2)
ConnectionPointgetIntersection in class ConnectionPointpublic android.graphics.PointF getInitialPoint()
ConnectionPointgetInitialPoint in class ConnectionPointpublic void addLinkToNode()
ConnectionPointaddLinkToNode in class ConnectionPointpublic void removeLinkFromNode()
ConnectionPointremoveLinkFromNode in class ConnectionPointpublic void saveEndRelative()
ConnectionPointsaveEndRelative in class ConnectionPointpublic android.graphics.PointF getEndPoint()
ConnectionPointgetEndPoint in class ConnectionPointpublic boolean calculateIntersections()
ConnectionPointcalculateIntersections in class ConnectionPointpublic android.graphics.PointF getAnchorPos(int anchorIdx)
ConnectionPointgetAnchorPos in class ConnectionPointpublic boolean getAnchorPos(int anchorIdx,
android.graphics.PointF point)
getAnchorPos in class ConnectionPointpublic void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
ConnectionPointwriteExternal in interface java.io.ExternalizablewriteExternal in class ConnectionPointjava.io.IOExceptionpublic void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
ConnectionPointreadExternal in interface java.io.ExternalizablereadExternal in class ConnectionPointjava.io.IOExceptionjava.lang.ClassNotFoundException