|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--org.tigris.gef.graph.MutableGraphSupport
|
+--com.bonevich.erj.diagram.ERDiagramGraphModel
This class defines a bridge between the Relational meta-model representation of the database design and the GraphModel interface used by GEF.
| Field Summary |
| Fields inherited from class org.tigris.gef.graph.MutableGraphSupport |
_graphListeners |
| Constructor Summary | |
ERDiagramGraphModel()
|
|
ERDiagramGraphModel(Schema schema)
|
|
| Method Summary | |
void |
addEdge(java.lang.Object edge)
Add the given edge to the graph, if valid. |
void |
addNode(java.lang.Object node)
Add the given node to the graph, if valid. |
void |
addNodeRelatedEdges(java.lang.Object node)
Add existing edges that are related to the node. |
boolean |
canAddEdge(java.lang.Object edge)
Return true if the given object is a valid edge in this graph |
boolean |
canAddNode(java.lang.Object node)
Return true if the given object is a valid node in this graph |
boolean |
canConnect(java.lang.Object fromP,
java.lang.Object toP)
Return true if the two given ports can be connected by a kind of edge to be determined by the ports. |
java.lang.Object |
connect(java.lang.Object fromPort,
java.lang.Object toPort)
Contruct and add a new edge of a kind determined by the ports |
java.lang.Object |
connect(java.lang.Object fromPort,
java.lang.Object toPort,
java.lang.Class edgeClass)
Contruct and add a new edge of the given kind |
void |
fireGraphChanged(java.lang.Object nodeOrEdge)
This method provides a signature taking a node or edge as an argument (unlike the method in MutableGraphSupport, which takes no arguments). |
java.lang.Object |
getDestPort(java.lang.Object edge)
Return the other end of an edge |
java.util.Vector |
getEdges()
Return all edges in the graph |
java.util.Vector |
getInEdges(java.lang.Object port)
Return all edges going to given port |
java.util.Vector |
getNodes()
Return all nodes in the graph |
java.util.Vector |
getOutEdges(java.lang.Object port)
Return all edges going from given port |
java.lang.Object |
getOwner(java.lang.Object port)
Return the node or edge that owns the given port |
java.util.Vector |
getPorts(java.lang.Object nodeOrEdge)
Return all ports on node or edge |
Schema |
getSchema()
|
java.lang.Object |
getSourcePort(java.lang.Object edge)
Return one end of an edge |
void |
removeEdge(java.lang.Object edge)
Remove the given edge from the graph. |
void |
removeNode(java.lang.Object node)
Remove the given node from the graph. |
| Methods inherited from class org.tigris.gef.graph.MutableGraphSupport |
addGraphEventListener, canConnect, canDragNode, containsEdge, containsEdgePort, containsNode, containsNodePort, containsPort, dragNode, fireEdgeAdded, fireEdgeRemoved, fireGraphChanged, fireNodeAdded, fireNodeRemoved, getGraphListeners, removeGraphEventListener |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.tigris.gef.graph.MutableGraphModel |
canConnect, canDragNode, containsEdge, containsNode, dragNode |
| Methods inherited from interface org.tigris.gef.graph.GraphModel |
addGraphEventListener, removeGraphEventListener |
| Constructor Detail |
public ERDiagramGraphModel()
public ERDiagramGraphModel(Schema schema)
| Method Detail |
public Schema getSchema()
public java.util.Vector getNodes()
getNodes in interface org.tigris.gef.graph.GraphModelgetNodes in class org.tigris.gef.graph.MutableGraphSupportpublic java.util.Vector getEdges()
getEdges in interface org.tigris.gef.graph.GraphModelgetEdges in class org.tigris.gef.graph.MutableGraphSupportpublic java.util.Vector getPorts(java.lang.Object nodeOrEdge)
getPorts in interface org.tigris.gef.graph.GraphModelgetPorts in class org.tigris.gef.graph.MutableGraphSupportpublic java.lang.Object getOwner(java.lang.Object port)
getOwner in interface org.tigris.gef.graph.GraphModelgetOwner in class org.tigris.gef.graph.MutableGraphSupportpublic java.util.Vector getInEdges(java.lang.Object port)
getInEdges in interface org.tigris.gef.graph.GraphModelgetInEdges in class org.tigris.gef.graph.MutableGraphSupportpublic java.util.Vector getOutEdges(java.lang.Object port)
getOutEdges in interface org.tigris.gef.graph.GraphModelgetOutEdges in class org.tigris.gef.graph.MutableGraphSupportpublic java.lang.Object getSourcePort(java.lang.Object edge)
getSourcePort in interface org.tigris.gef.graph.GraphModelgetSourcePort in class org.tigris.gef.graph.MutableGraphSupportpublic java.lang.Object getDestPort(java.lang.Object edge)
getDestPort in interface org.tigris.gef.graph.GraphModelgetDestPort in class org.tigris.gef.graph.MutableGraphSupportpublic boolean canAddNode(java.lang.Object node)
canAddNode in interface org.tigris.gef.graph.MutableGraphModelcanAddNode in class org.tigris.gef.graph.MutableGraphSupportpublic boolean canAddEdge(java.lang.Object edge)
canAddEdge in interface org.tigris.gef.graph.MutableGraphModelcanAddEdge in class org.tigris.gef.graph.MutableGraphSupportpublic void addNode(java.lang.Object node)
addNode in interface org.tigris.gef.graph.MutableGraphModeladdNode in class org.tigris.gef.graph.MutableGraphSupportpublic void removeNode(java.lang.Object node)
removeNode in interface org.tigris.gef.graph.MutableGraphModelremoveNode in class org.tigris.gef.graph.MutableGraphSupportpublic void addEdge(java.lang.Object edge)
addEdge in interface org.tigris.gef.graph.MutableGraphModeladdEdge in class org.tigris.gef.graph.MutableGraphSupportpublic void removeEdge(java.lang.Object edge)
removeEdge in interface org.tigris.gef.graph.MutableGraphModelremoveEdge in class org.tigris.gef.graph.MutableGraphSupportpublic void addNodeRelatedEdges(java.lang.Object node)
addNodeRelatedEdges in interface org.tigris.gef.graph.MutableGraphModeladdNodeRelatedEdges in class org.tigris.gef.graph.MutableGraphSupport
public boolean canConnect(java.lang.Object fromP,
java.lang.Object toP)
canConnect in interface org.tigris.gef.graph.MutableGraphModelcanConnect in class org.tigris.gef.graph.MutableGraphSupport
public java.lang.Object connect(java.lang.Object fromPort,
java.lang.Object toPort)
connect in interface org.tigris.gef.graph.MutableGraphModelconnect in class org.tigris.gef.graph.MutableGraphSupport
public java.lang.Object connect(java.lang.Object fromPort,
java.lang.Object toPort,
java.lang.Class edgeClass)
connect in interface org.tigris.gef.graph.MutableGraphModelconnect in class org.tigris.gef.graph.MutableGraphSupportpublic void fireGraphChanged(java.lang.Object nodeOrEdge)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||