Package org.extendj.neobeaver.ast
Class Opt<T extends ASTNode>
- java.lang.Object
-
- org.extendj.neobeaver.ast.ASTNode<T>
-
- org.extendj.neobeaver.ast.Opt<T>
-
- All Implemented Interfaces:
java.lang.Cloneable,Parser.Symbol
public class Opt<T extends ASTNode> extends ASTNode<T> implements java.lang.Cloneable
-
-
Field Summary
-
Fields inherited from class org.extendj.neobeaver.ast.ASTNode
children, generatedWithCacheCycle, numChildren, parent
-
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Opt<T>clone()Opt<T>copy()voidflushAttrCache()voidflushCollectionCache()Opt<T>fullCopy()Deprecated.Please use treeCopy or treeCopyNoTransform insteadvoidinit$Children()Initializes the child array to the correct size.protected booleanis$Equal(ASTNode node)Opt<T>treeCopy()Create a deep copy of the AST subtree at this node.Opt<T>treeCopyNoTransform()Create a deep copy of the AST subtree at this node.-
Methods inherited from class org.extendj.neobeaver.ast.ASTNode
accept, addChild, astChildIterator, astChildren, doFullTraversal, flushAttrAndCollectionCache, flushCache, flushTreeCache, getChild, getChildNoTransform, getIndexOfChild, getNumChild, getNumChildNoTransform, getParent, getPosition, insertChild, is$Equal, numChildren, removeChild, resetState, rewrittenNode, setChild, setParent, setPosition, state
-
-
-
-
Constructor Detail
-
Opt
public Opt()
-
Opt
public Opt(T opt)
-
-
Method Detail
-
init$Children
public void init$Children()
Initializes the child array to the correct size. Initializes List and Opt nta children.- Overrides:
init$Childrenin classASTNode<T extends ASTNode>
-
flushAttrCache
public void flushAttrCache()
- Overrides:
flushAttrCachein classASTNode<T extends ASTNode>
-
flushCollectionCache
public void flushCollectionCache()
- Overrides:
flushCollectionCachein classASTNode<T extends ASTNode>
-
fullCopy
@Deprecated public Opt<T> fullCopy()
Deprecated.Please use treeCopy or treeCopyNoTransform insteadCreate a deep copy of the AST subtree at this node. The copy is dangling, i.e. has no parent.
-
treeCopyNoTransform
public Opt<T> treeCopyNoTransform()
Create a deep copy of the AST subtree at this node. The copy is dangling, i.e. has no parent.- Overrides:
treeCopyNoTransformin classASTNode<T extends ASTNode>- Returns:
- dangling copy of the subtree at this node
-
treeCopy
public Opt<T> treeCopy()
Create a deep copy of the AST subtree at this node. The subtree of this node is traversed to trigger rewrites before copy. The copy is dangling, i.e. has no parent.
-
-