Package javassist.compiler.ast
Class ASTree
- java.lang.Object
-
- javassist.compiler.ast.ASTree
-
- All Implemented Interfaces:
java.io.Serializable
public abstract class ASTree extends java.lang.Object implements java.io.Serializable
Abstract Syntax Tree. An ASTree object represents a node of a binary tree. If the node is a leaf node, bothgetLeft()
andgetRight()
returns null.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ASTree()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
accept(Visitor v)
Is a method for the visitor pattern.ASTree
getLeft()
ASTree
getRight()
protected java.lang.String
getTag()
Returns the type of this node.void
setLeft(ASTree _left)
void
setRight(ASTree _right)
java.lang.String
toString()
-
-
-
Method Detail
-
getLeft
public ASTree getLeft()
-
getRight
public ASTree getRight()
-
setLeft
public void setLeft(ASTree _left)
-
setRight
public void setRight(ASTree _right)
-
accept
public abstract void accept(Visitor v) throws CompileError
Is a method for the visitor pattern. It callsatXXX()
on the given visitor, whereXXX
is the class name of the node object.- Throws:
CompileError
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
getTag
protected java.lang.String getTag()
Returns the type of this node. This method is used bytoString()
.
-
-