All Packages Class Hierarchy This Package Previous Next Index
Interface openjava.ptree.Ptree
- public interface Ptree
The Ptree class presents for the node of parse tree.
This may be a token node, Leaf, or may be a nonterminal node, NonLeaf.
- See Also:
- Leaf, NonLeaf
-
eq(Ptree)
- Tests if this parse-tree-node's value equals to the specified
ptree-node's.
-
equals(Ptree)
- Tests if this parse-tree-node's value equals to the specified
ptree-node's.
-
getObjectID()
- Returns the Identifier Number of this object
-
makeCopy()
- Makes a new copy of this nonleaf-node as a ptree-node.
-
makeRecursiveCopy()
- Makes a new copy (another object) of this nonleaf-node recursively.
-
toFlattenString()
- Generates the string expression from this node.
-
toString()
- Generates string which presents for this parse-tree
-
writeCode()
- Writes a source code in the writer(stream).
makeRecursiveCopy
public abstract Ptree makeRecursiveCopy()
- Makes a new copy (another object) of this nonleaf-node recursively.
The objects contained by this object will also be copied.
- Returns:
- the copy of this nonleaf-node as a ptree-node.
makeCopy
public abstract Ptree makeCopy()
- Makes a new copy of this nonleaf-node as a ptree-node.
The objects contained by the new object are same as
these contained by the original object.
- Returns:
- the copy of this nonleaf-node as a ptree-node.
equals
public abstract boolean equals(Ptree p)
- Tests if this parse-tree-node's value equals to the specified
ptree-node's.
- Returns:
- true if two values are same.
eq
public abstract boolean eq(Ptree p)
- Tests if this parse-tree-node's value equals to the specified
ptree-node's.
- Returns:
- true if two this and p refer to the same ptree object.
toString
public abstract String toString()
- Generates string which presents for this parse-tree
- Returns:
- string which presents for this parse-tree
- Overrides:
- toString in class Object
writeCode
public abstract void writeCode()
- Writes a source code in the writer(stream).
This must be overridden.
toFlattenString
public abstract String toFlattenString()
- Generates the string expression from this node.
Returned string doesn't have '"' without cancel ( \" )
and doesn't have newline.
- Returns:
- the flatten string which this node presents for
getObjectID
public abstract int getObjectID()
- Returns the Identifier Number of this object
- Returns:
- the ID number of this object
All Packages Class Hierarchy This Package Previous Next Index