edu.iastate.anthill.shared
Class TypedNode

java.lang.Object
  extended byjavax.swing.tree.DefaultMutableTreeNode
      extended byedu.iastate.anthill.shared.TypedNode
All Implemented Interfaces:
java.lang.Cloneable, java.lang.Comparable, javax.swing.tree.MutableTreeNode, java.io.Serializable, javax.swing.tree.TreeNode
Direct Known Subclasses:
DataSourceNode

public class TypedNode
extends javax.swing.tree.DefaultMutableTreeNode
implements java.lang.Comparable

Node with a type

Since:
1.0 2004-10-02
Author:
Jie Bao
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class javax.swing.tree.DefaultMutableTreeNode
 
Field Summary
static short ALL_CLASSES
           
static short ALL_INSTANCES
           
static short ALL_PROPERTIES
           
static short AVH
           
static short CLASS
           
(package private)  java.awt.Color color
           
protected  java.lang.Object comment
           
static short DB
           
static short DOMAIN
           
static short INSTANCE
           
static short kindsOfNode
           
static short PACKAGE
           
static short PROPERTY
           
static short ROOT
           
static short SCHEMA
           
protected  short type
           
 
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject
 
Constructor Summary
TypedNode()
          TypedNode
TypedNode(java.lang.Object userObject)
           
TypedNode(java.lang.Object userObject, short type, java.lang.String comment)
           
 
Method Summary
 int compareTo(java.lang.Object o)
           
 boolean equals(java.lang.Object node)
           
 void fromXML(java.lang.String xml)
          read from XML - plain text only YET
 java.awt.Color getColor()
           
 java.lang.Object getComment()
           
 java.lang.String getLocalName()
          Get name of the node
 short getType()
           
 void setColor(java.awt.Color color)
           
 void setComment(java.lang.Object comment)
           
 void setType(short type)
           
 java.lang.String toXML()
          toXML - plain text only YET
 
Methods inherited from class javax.swing.tree.DefaultMutableTreeNode
add, breadthFirstEnumeration, children, clone, depthFirstEnumeration, getAllowsChildren, getChildAfter, getChildAt, getChildBefore, getChildCount, getDepth, getFirstChild, getFirstLeaf, getIndex, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getParent, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isLeaf, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject, toString
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

type

protected short type

comment

protected java.lang.Object comment

color

java.awt.Color color

ROOT

public static final short ROOT
See Also:
Constant Field Values

ALL_CLASSES

public static final short ALL_CLASSES
See Also:
Constant Field Values

ALL_PROPERTIES

public static final short ALL_PROPERTIES
See Also:
Constant Field Values

ALL_INSTANCES

public static final short ALL_INSTANCES
See Also:
Constant Field Values

CLASS

public static final short CLASS
See Also:
Constant Field Values

PROPERTY

public static final short PROPERTY
See Also:
Constant Field Values

INSTANCE

public static final short INSTANCE
See Also:
Constant Field Values

PACKAGE

public static final short PACKAGE
See Also:
Constant Field Values

DOMAIN

public static final short DOMAIN
See Also:
Constant Field Values

SCHEMA

public static final short SCHEMA
See Also:
Constant Field Values

AVH

public static final short AVH
See Also:
Constant Field Values

DB

public static final short DB
See Also:
Constant Field Values

kindsOfNode

public static final short kindsOfNode
See Also:
Constant Field Values
Constructor Detail

TypedNode

public TypedNode(java.lang.Object userObject)

TypedNode

public TypedNode(java.lang.Object userObject,
                 short type,
                 java.lang.String comment)
Parameters:
userObject - Object
type - short
comment - String
Since:
2004-10-18

TypedNode

public TypedNode()
TypedNode

Method Detail

getType

public short getType()

setType

public void setType(short type)

equals

public boolean equals(java.lang.Object node)

getLocalName

public java.lang.String getLocalName()
Get name of the node

Since:
2004-10-13

getComment

public java.lang.Object getComment()

getColor

public java.awt.Color getColor()

setComment

public void setComment(java.lang.Object comment)

setColor

public void setColor(java.awt.Color color)

toXML

public java.lang.String toXML()
toXML - plain text only YET

Returns:
String
Since:
2004-10-18

fromXML

public void fromXML(java.lang.String xml)
read from XML - plain text only YET

Parameters:
xml - String
Since:
2004-10-18

compareTo

public int compareTo(java.lang.Object o)
Specified by:
compareTo in interface java.lang.Comparable
Parameters:
o - Object
Returns:
int
Since:
2004-10-18