|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--utilities.GraphNode
This is a superclass for the generic purpose of drawing graphs made up of nodes and edges. Its primary purpose is for the resource hierarchy interface.
It should probably not be instantiated directly. It is modeled after taems' Node class, minus the agent/tames specific stuff.
Constructor Summary | |
GraphNode()
Blank Constructor |
|
GraphNode(java.lang.String l)
Default constructor |
Method Summary | |
void |
addEdge(GraphEdge e,
GraphNode t)
|
void |
addEdge(GraphNode t)
|
java.lang.Object |
clone()
|
int |
compareTo(java.lang.Object o)
|
boolean |
equals(java.lang.Object o)
|
void |
excise()
|
java.lang.Object |
getAttribute(java.lang.Object k)
Note that this uses the toString() method for the key to actually store the object. |
java.util.Enumeration |
getAttributes()
Returns the attribute names |
javax.swing.JPanel |
getDefaultPanel()
Drawing stuff * |
java.util.Enumeration |
getInEdges()
|
java.lang.String |
getLabel()
Accessors |
java.util.Enumeration |
getOutEdges()
|
java.util.Enumeration |
getUndirEdges()
|
boolean |
hasAttribute(java.lang.Object k)
Determines if the node has a particular attribute |
boolean |
hasInEdges()
|
boolean |
hasOutEdges()
|
boolean |
hasUndirEdges()
|
boolean |
matches(java.lang.Object o)
|
int |
numInEdges()
|
int |
numOutEdges()
|
int |
numUndirEdges()
|
void |
removeEdge(GraphEdge e)
|
void |
removeEdge(GraphNode t)
|
void |
saveCfg()
saves the information in this object to the proper location in the CfgManager. |
void |
setAttribute(java.lang.Object k,
java.lang.Object d)
Sets an attribute's data. |
void |
setLabel(java.lang.String l)
|
java.lang.String |
toString()
|
void |
updateCfg()
updates the information in this object with information currently in the CfgManager. |
Methods inherited from class java.lang.Object |
getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public GraphNode(java.lang.String l)
l
- The node's labelpublic GraphNode()
Method Detail |
public void updateCfg()
ConfiguredObject
updateCfg
in interface ConfiguredObject
public void saveCfg()
ConfiguredObject
saveCfg
in interface ConfiguredObject
public java.lang.String getLabel()
public void setLabel(java.lang.String l)
public java.lang.Object getAttribute(java.lang.Object k)
k
- The key identifying the desired attributepublic void setAttribute(java.lang.Object k, java.lang.Object d)
If a key is added with a null data object, the key will be removed from the attribute set.
k
- The key identifying the desired attributed
- The attribute datapublic java.util.Enumeration getAttributes()
public boolean hasAttribute(java.lang.Object k)
public void addEdge(GraphNode t)
public void removeEdge(GraphNode t)
public void addEdge(GraphEdge e, GraphNode t)
public void removeEdge(GraphEdge e)
public java.util.Enumeration getOutEdges()
public boolean hasOutEdges()
public int numOutEdges()
public java.util.Enumeration getInEdges()
public java.util.Enumeration getUndirEdges()
public boolean hasUndirEdges()
public int numUndirEdges()
public boolean hasInEdges()
public int numInEdges()
public void excise()
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public boolean matches(java.lang.Object o)
public java.lang.Object clone()
public java.lang.String toString()
toString
in class java.lang.Object
public javax.swing.JPanel getDefaultPanel()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |