Package javassist.compiler.ast
Class ASTList
java.lang.Object
javassist.compiler.ast.ASTree
javassist.compiler.ast.ASTList
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
ArrayInit,CastExpr,CondExpr,Declarator,Expr,FieldDecl,MethodDecl,NewExpr,Stmnt
A linked list.
The right subtree must be an ASTList object or null.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidIs a method for the visitor pattern.static ASTListAppends an object to a list.static ASTListConcatenates two lists.getLeft()getRight()head()Returns the car part of the list.intlength()Returns the number of the elements in this list.static intstatic ASTListvoidvoidvoidvoidsublist(int nth) Returns a sub list of the list.booleanSubstitutesnewObjforoldObjin the list.tail()Returns the cdr part of the list.toString()
-
Constructor Details
-
ASTList
-
ASTList
-
-
Method Details
-
make
-
getLeft
-
getRight
-
setLeft
-
setRight
-
head
Returns the car part of the list. -
setHead
-
tail
Returns the cdr part of the list. -
setTail
-
accept
Description copied from class:ASTreeIs a method for the visitor pattern. It callsatXXX()on the given visitor, whereXXXis the class name of the node object. -
toString
-
length
public int length()Returns the number of the elements in this list. -
length
-
sublist
Returns a sub list of the list. The sub list begins with the n-th element of the list.- Parameters:
nth- zero or more than zero.
-
subst
SubstitutesnewObjforoldObjin the list. -
append
Appends an object to a list. -
concat
Concatenates two lists.
-