|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectptolemy.vergil.kernel.CompositePtolemyModel
public class CompositePtolemyModel
A diva node model for a Ptolemy II composite entity. Each element of the graph model is represented by an instance of Locatable, which is an attribute contained by a Ptolemy II object. If a Ptolemy II object is found that does not contain a Locatable, then one is created if needed. The graph model consists of locations for various elements in the composite. In particular, one location will be included for each contained entity, port, director, and visible attribute. In each case except visible attributes, if there is no location, then a default location is created. Visible attributes are included in the graph only if they already contain a location. In addition, for any relation that links more than two ports and does not contain a Vertex, this class will create a Vertex.
Location
Red (johnr) |
Yellow (neuendor) |
Field Summary | |
---|---|
private java.lang.Object |
_composite
|
private java.lang.Object |
_compositeAfter
|
private java.lang.Object |
_compositeBefore
|
private java.util.List |
_nodeList
|
private java.util.List |
_nodeListAfter
|
private java.util.List |
_nodeListBefore
|
private long |
_version
|
private long |
_versionAfter
|
private long |
_versionBefore
|
Constructor Summary | |
---|---|
CompositePtolemyModel()
|
Method Summary | |
---|---|
protected Locatable |
_getLocation(NamedObj object)
Return the location attribute contained in the given object, or a new location contained in the given object if there was no location. |
private java.util.List |
_nodeList(NamedObj composite,
boolean before,
boolean after)
Return a list of all the nodes in the graph corresponding to the specified Ptolemy II model. |
int |
getNodeCount(java.lang.Object composite)
Return the number of nodes contained in the graph for the specified composite. |
java.util.Iterator |
nodes(java.lang.Object composite)
Return an iterator over all the nodes contained in the graph for the specified composite. |
java.util.Iterator |
nodesAfterEdges(java.lang.Object composite)
Return an iterator over the nodes that should be rendered after to the edges. |
java.util.Iterator |
nodesBeforeEdges(java.lang.Object composite)
Return an iterator over the nodes that should be rendered prior to the edges. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.lang.Object _composite
private java.lang.Object _compositeBefore
private java.lang.Object _compositeAfter
private java.util.List _nodeList
private java.util.List _nodeListBefore
private java.util.List _nodeListAfter
private long _version
private long _versionBefore
private long _versionAfter
Constructor Detail |
---|
public CompositePtolemyModel()
Method Detail |
---|
public int getNodeCount(java.lang.Object composite)
getNodeCount
in interface CompositeModel
composite
- A composite entity.
public java.util.Iterator nodes(java.lang.Object composite)
nodes
in interface CompositeModel
composite
- A composite entity.
public java.util.Iterator nodesBeforeEdges(java.lang.Object composite)
nodesBeforeEdges
in interface CompositeModel
composite
- The composite.
public java.util.Iterator nodesAfterEdges(java.lang.Object composite)
nodesAfterEdges
in interface CompositeModel
composite
- The composite.
protected Locatable _getLocation(NamedObj object)
object
- The object for which a location is needed.
private java.util.List _nodeList(NamedObj composite, boolean before, boolean after)
composite
- The composite entity.before
- True to include nodes to be rendered before edges.after
- True to include nodes to be rendered after edges.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |