|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.tigris.gef.graph.MutableGraphSupport
org.argouml.uml.diagram.UMLMutableGraphSupport
org.argouml.uml.diagram.static_structure.ClassDiagramGraphModel
This class defines a bridge between the UML meta-model representation of the design and the GraphModel interface used by GEF. This class handles only UML Class digrams.
| Constructor Summary | |
ClassDiagramGraphModel()
|
|
| Method Summary | |
void |
addEdge(Object edge)
Add the given edge to the graph, if of the correct type. |
void |
addNode(Object node)
|
void |
addNodeRelatedEdges(Object node)
Adds the edges from the given node. |
boolean |
canAddEdge(Object edge)
|
boolean |
canAddNode(Object node)
|
boolean |
canChangeConnectedNode(Object newNode,
Object oldNode,
Object edge)
When rerouting an edge, this is the first method to be called by SelectionRerouteEdge, in order to determine whether the graphmodel will allow the change. |
void |
changeConnectedNode(Object newNode,
Object oldNode,
Object edge,
boolean isSource)
Reroutes the connection to the old node to be connected to the new node. |
List |
getInEdges(Object port)
|
List |
getOutEdges(Object port)
|
Object |
getOwner(Object port)
|
List |
getPorts(Object nodeOrEdge)
|
void |
vetoableChange(PropertyChangeEvent pce)
|
| Methods inherited from class org.argouml.uml.diagram.UMLMutableGraphSupport |
buildCommentConnection, buildConnection, canConnect, connect, connect, connect, connect, constainsEdge, containsNode, getDestPort, getDiDiagram, getEdges, getHomeModel, getNodes, getSourcePort, isConnectionValid, isRemoveFromDiagramAllowed, removeEdge, removeNode, setHomeModel |
| Methods inherited from class org.tigris.gef.graph.MutableGraphSupport |
addGraphEventListener, canConnect, canConnect, canDragNode, containsEdge, containsEdgePort, containsNodePort, containsPort, createNode, dragNode, enableSaveAction, fireEdgeAdded, fireEdgeRemoved, fireGraphChanged, fireNodeAdded, fireNodeRemoved, getConnectionConstrainer, getGraphListeners, isEnclosable, removeAll, removeAllEdges, removeAllNodes, removeFig, removeGraphEventListener, setConnectionConstrainer, setSaveAction |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ClassDiagramGraphModel()
| Method Detail |
public List getPorts(Object nodeOrEdge)
getPorts in interface GraphModelReturn all ports on node or edge.public Object getOwner(Object port)
getOwner in interface BaseGraphModelReturn the node or edge that owns the given port.public List getInEdges(Object port)
getInEdges in interface GraphModelReturn all edges going to given port (read Model Element).
Instances can't currently be added to a class diagram.public List getOutEdges(Object port)
getOutEdges in interface GraphModelReturn all edges going from given port (model element).public boolean canAddNode(Object node)
canAddNode in interface MutableGraphModelcanAddNode in class UMLMutableGraphSupportReturn true if the given object is a valid node in this graph.public boolean canAddEdge(Object edge)
canAddEdge in interface MutableGraphModelcanAddEdge in class UMLMutableGraphSupportReturn true if the given object is a valid edge in this graph.public void addNode(Object node)
addNode in interface MutableGraphModelAdd the given node to the graph, if valid.public void addEdge(Object edge)
addEdge in interface MutableGraphModelMutableGraphModel.addEdge(java.lang.Object)public void addNodeRelatedEdges(Object node)
addNodeRelatedEdges in interface MutableGraphModeladdNodeRelatedEdges in class UMLMutableGraphSupportMutableGraphModel.addNodeRelatedEdges(Object)public void vetoableChange(PropertyChangeEvent pce)
vetoableChange in interface VetoableChangeListenerVetoableChangeListener.vetoableChange(java.beans.PropertyChangeEvent)
public boolean canChangeConnectedNode(Object newNode,
Object oldNode,
Object edge)
Restricted to class-association changes for now.
canChangeConnectedNode in interface MutableGraphModelnewNode - this is the new node that one of the ends is dragged to.oldNode - this is the existing node that is already connected.edge - this is the edge that is being dragged/rerouted
public void changeConnectedNode(Object newNode,
Object oldNode,
Object edge,
boolean isSource)
changeConnectedNode in interface MutableGraphModelnewNode - this is the new node that one of the ends is dragged to.oldNode - this is the existing node that is already connected.edge - this is the edge that is being dragged/reroutedisSource - tells us which end is being rerouted.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
| ArgoUML © 1996-2006 | ArgoUML Homepage | ArgoUML Developers' page | ArgoUML Cookbook |