|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.uima.internal.util.GraphNode
public class GraphNode
Interface for a generic node in a graph.
Graph| Field Summary | |
|---|---|
protected java.lang.Object |
element
|
protected java.util.ArrayList<GraphNode> |
predecessors
|
protected java.util.ArrayList<GraphNode> |
successors
|
| Constructor Summary | |
|---|---|
GraphNode(java.lang.Object element)
|
|
| Method Summary | |
|---|---|
void |
addPredecessor(GraphNode pred)
Add a new predecessor node. |
void |
addSuccessor(GraphNode succ)
Add a new successor node. |
void |
connect(GraphNode node)
Connect this node to a new node. |
java.lang.Object |
getElement()
Get the element contained in the node. |
int |
getNbrPred()
Get the number of predecessor node. |
int |
getNbrSucc()
Get the number of successor node. |
GraphNode |
getPredecessor(int i)
Get a specific predecessor node. |
GraphNode |
getSuccessor(int i)
Get a specific successor node. |
void |
setElement(java.lang.Object element)
Set the element in the node. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected java.lang.Object element
protected java.util.ArrayList<GraphNode> successors
protected java.util.ArrayList<GraphNode> predecessors
| Constructor Detail |
|---|
public GraphNode(java.lang.Object element)
| Method Detail |
|---|
public java.lang.Object getElement()
public void setElement(java.lang.Object element)
element - The element.public int getNbrSucc()
public GraphNode getSuccessor(int i)
i - The number of the successor to be retrieved.
public void addSuccessor(GraphNode succ)
dtr - The node to be added.public int getNbrPred()
public GraphNode getPredecessor(int i)
i - The number of the predecessor to be retrieved.
public void addPredecessor(GraphNode pred)
pred - The node to be added.public void connect(GraphNode node)
node - The node to be connected to.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||