public abstract class ModularGraphModel extends AbstractGraphModel
_graphListeners
Constructor and Description |
---|
ModularGraphModel(java.lang.Object root)
Construct an empty graph model whose
root is the given semantic object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
containsNode(java.lang.Object composite,
java.lang.Object node)
Return true if this composite node contains the given node.
|
abstract CompositeModel |
getCompositeModel(java.lang.Object composite)
Return the model for the given composite object.
|
abstract EdgeModel |
getEdgeModel(java.lang.Object edge)
Return the model for the given edge object.
|
java.lang.Object |
getHead(java.lang.Object edge)
Return the head node of the given edge.
|
int |
getNodeCount(java.lang.Object composite)
Return the number of nodes contained in
this graph or composite node.
|
abstract NodeModel |
getNodeModel(java.lang.Object node)
Return the node model for the given object.
|
java.lang.Object |
getParent(java.lang.Object node)
Return the parent graph of this node, return
null if there is no parent.
|
abstract java.lang.Object |
getProperty(java.lang.Object o,
java.lang.String propertyName)
Return the property of the object associated with
the given property name.
|
java.lang.Object |
getRoot()
Return the root graph of this graph model.
|
abstract java.lang.Object |
getSemanticObject(java.lang.Object o)
Return the semantic object corresponding
to the given node, edge, or composite.
|
java.lang.Object |
getTail(java.lang.Object edge)
Return the tail node of this edge.
|
java.util.Iterator |
inEdges(java.lang.Object node)
Return an iterator over the in edges of this
node.
|
boolean |
isComposite(java.lang.Object o)
Return true if the given object is a composite
node in this model, i.e. it contains children.
|
boolean |
isDirected(java.lang.Object edge)
Return whether or not this edge is directed.
|
boolean |
isEdge(java.lang.Object o)
Return true if the given object is a
node in this model.
|
boolean |
isNode(java.lang.Object o)
Return true if the given object is a
node in this model.
|
java.util.Iterator |
nodes(java.lang.Object composite)
Provide an iterator over the nodes in the
given graph or composite node.
|
java.util.Iterator |
nodesAfterEdges(java.lang.Object composite)
Provide an iterator over the nodes that should
be rendered after to the edges.
|
java.util.Iterator |
nodesBeforeEdges(java.lang.Object composite)
Provide an iterator over the nodes that should
be rendered prior to the edges.
|
java.util.Iterator |
outEdges(java.lang.Object node)
Return an iterator over the out edges of this
node.
|
abstract void |
setProperty(java.lang.Object o,
java.lang.String propertyName,
java.lang.Object value)
Set the property of the object associated with
the given property name.
|
abstract void |
setSemanticObject(java.lang.Object o,
java.lang.Object sem)
Set the semantic object corresponding
to the given node, edge, or composite.
|
addGraphListener, dispatchGraphEvent, removeGraphListener, setDispatchEnabled
public ModularGraphModel(java.lang.Object root)
public boolean containsNode(java.lang.Object composite, java.lang.Object node)
public abstract CompositeModel getCompositeModel(java.lang.Object composite)
public abstract EdgeModel getEdgeModel(java.lang.Object edge)
public java.lang.Object getHead(java.lang.Object edge)
public int getNodeCount(java.lang.Object composite)
public abstract NodeModel getNodeModel(java.lang.Object node)
public java.lang.Object getParent(java.lang.Object node)
public abstract java.lang.Object getProperty(java.lang.Object o, java.lang.String propertyName)
public java.lang.Object getRoot()
public abstract java.lang.Object getSemanticObject(java.lang.Object o)
public java.lang.Object getTail(java.lang.Object edge)
public boolean isDirected(java.lang.Object edge)
public boolean isComposite(java.lang.Object o)
public boolean isEdge(java.lang.Object o)
public boolean isNode(java.lang.Object o)
public java.util.Iterator nodes(java.lang.Object composite)
public java.util.Iterator nodesBeforeEdges(java.lang.Object composite)
public java.util.Iterator nodesAfterEdges(java.lang.Object composite)
public java.util.Iterator inEdges(java.lang.Object node)
public java.util.Iterator outEdges(java.lang.Object node)
public abstract void setProperty(java.lang.Object o, java.lang.String propertyName, java.lang.Object value)
public abstract void setSemanticObject(java.lang.Object o, java.lang.Object sem)