|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.esa.beam.framework.gpf.graph.Graph
public class Graph
Represents a directed acyclic graph (DAG) of Nodes.
| Field Summary | |
|---|---|
static String |
CURRENT_VERSION
|
| Constructor Summary | |
|---|---|
Graph(String id)
Constructs an empty graph with the given id. |
|
| Method Summary | |
|---|---|
void |
addNode(Node node)
Adds a Node to the graph |
com.thoughtworks.xstream.io.xml.xppdom.XppDom |
getApplicationData(String appId)
Returns the Application data for the given application ID or null, if for this id no application is available. |
Header |
getHeader()
Gets the graph's header |
String |
getId()
Gets the graph's id |
Node |
getNode(int index)
Gets the Node at the given index. |
Node |
getNode(String id)
Returns the Node with the given id or
null if the graph contains no respective Node. |
int |
getNodeCount()
Gets the number nodes contained by this graph. |
Node[] |
getNodes()
Returns an array containing all nodes in this graph. |
String |
getVersion()
Gets the graph's version |
boolean |
removeNode(String id)
Removes the Node with the given id from this graph if present. |
void |
setAppData(String id,
com.thoughtworks.xstream.io.xml.xppdom.XppDom data)
Sets the application data for the given ID |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String CURRENT_VERSION
| Constructor Detail |
|---|
public Graph(String id)
id.
id - the id of the graph| Method Detail |
|---|
public String getId()
public String getVersion()
public Header getHeader()
public int getNodeCount()
public void addNode(Node node)
Node to the graph
node - a node
IllegalArgumentException - if the id of the given node is already in usepublic boolean removeNode(String id)
Node with the given id from this graph if present.
id - the id of the Node to be removed
true if the graph contains a Node with the given id. Else false.public Node getNode(int index)
Node at the given index.
index - the index
public Node getNode(String id)
Node with the given id or
null if the graph contains no respective Node.
id - the id of the Node to be removed
true if the graph contains a Node with the given id. Else false.public Node[] getNodes()
public com.thoughtworks.xstream.io.xml.xppdom.XppDom getApplicationData(String appId)
appId - the application ID
public void setAppData(String id,
com.thoughtworks.xstream.io.xml.xppdom.XppDom data)
id - The application ID.data - The application data as XppDom.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||