|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.tree.DefaultMutableTreeNode
org.jgraph.graph.DefaultGraphCell
com.jgraph.example.portlabels.PortLabelCell
public class PortLabelCell
Graph model cell that has a number of fixed offset ports on the left and right hand sides. It provides a number of utility methods to add and remove those ports.
| Field Summary |
|---|
| Fields inherited from class javax.swing.tree.DefaultMutableTreeNode |
|---|
EMPTY_ENUMERATION |
| Constructor Summary | |
|---|---|
PortLabelCell()
Default constructor |
|
PortLabelCell(java.lang.Object userObject)
Constructor with user object to set for cell. |
|
| Method Summary | |
|---|---|
org.jgraph.graph.Port |
addLeftPort(int position,
org.jgraph.graph.Port port,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Adds a port to the left hand side of the vertex at the specified position order |
org.jgraph.graph.Port |
addLeftPort(int position,
java.lang.String portLabel,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Adds a port with the specified label to the left hand side of the vertex at the specified position order |
org.jgraph.graph.Port |
addRightPort(int position,
org.jgraph.graph.Port port,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Adds a port to the right hand side of the vertex at the specified position order |
org.jgraph.graph.Port |
addRightPort(int position,
java.lang.String portLabel,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Adds a port with the specified label to the right hand side of the vertex at the specified position order |
int |
getNumLeftPorts()
|
int |
getNumRightPorts()
|
void |
removeLeftPort(int position,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Removes the left-hand side port at the specified position order |
void |
removeRightPort(int position,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
Removes the left-hand side port at the specified position order |
void |
setNumLeftPorts(int numLeftPorts)
|
void |
setNumRightPorts(int numRightPorts)
|
| Methods inherited from class org.jgraph.graph.DefaultGraphCell |
|---|
addPort, addPort, addPort, changeAttributes, clone, getAttributes, getChildren, setAttributes |
| Methods inherited from class javax.swing.tree.DefaultMutableTreeNode |
|---|
add, breadthFirstEnumeration, children, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildAt, getChildBefore, getChildCount, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public PortLabelCell()
public PortLabelCell(java.lang.Object userObject)
userObject - the userObject to set| Method Detail |
|---|
public org.jgraph.graph.Port addLeftPort(int position,
java.lang.String portLabel,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - this ports position in the order of port from top to bottomportLabel - the label to set for this port
public org.jgraph.graph.Port addLeftPort(int position,
org.jgraph.graph.Port port,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - this ports position in the order of port from top to bottomport - the instance of the new port
public org.jgraph.graph.Port addRightPort(int position,
java.lang.String portLabel,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - this ports position in the order of port from top to bottomportLabel - the label to set for this port
public org.jgraph.graph.Port addRightPort(int position,
org.jgraph.graph.Port port,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - this ports position in the order of port from top to bottomport - the instance of the new port
public void removeLeftPort(int position,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - the position order of the port to be removed
public void removeRightPort(int position,
java.util.Map nestedMap,
org.jgraph.graph.ParentMap parentMap)
position - the position order of the port to be removedpublic int getNumLeftPorts()
public void setNumLeftPorts(int numLeftPorts)
numLeftPorts - The numLeftPorts to set.public int getNumRightPorts()
public void setNumRightPorts(int numRightPorts)
numRightPorts - The numRightPorts to set.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||