public final class DetailAstImpl extends antlr.CommonASTWithHiddenTokens implements DetailAST
DetailAST
. This should only be directly used to
create custom AST nodes.Constructor and Description |
---|
DetailAstImpl() |
Modifier and Type | Method and Description |
---|---|
void |
addChild(antlr.collections.AST ast) |
void |
addNextSibling(DetailAST ast)
Add next sibling.
|
void |
addPreviousSibling(DetailAST ast)
Add previous sibling.
|
boolean |
branchContains(int type)
Checks if this branch of the parse tree contains a token
of the provided type.
|
DetailAST |
findFirstToken(int type)
Returns the first child token that makes a specified type.
|
int |
getChildCount()
Returns the number of child nodes one level below this node.
|
int |
getChildCount(int type)
Returns the number of direct child tokens that have the specified type.
|
int |
getColumnNo()
Gets column number.
|
DetailAstImpl |
getFirstChild()
Get the first child of this AST.
|
DetailAST |
getLastChild()
Gets the last child node.
|
int |
getLineNo()
Gets line number.
|
DetailAstImpl |
getNextSibling()
Get the next sibling in line after this one.
|
DetailAST |
getParent()
Returns the parent token.
|
DetailAST |
getPreviousSibling()
Returns the previous sibling or null if no such sibling exists.
|
boolean |
hasChildren()
Returns whether this AST has any children.
|
void |
initialize(antlr.collections.AST ast) |
void |
initialize(antlr.Token tok) |
void |
setColumnNo(int columnNo)
Set column number.
|
void |
setFirstChild(antlr.collections.AST ast) |
void |
setLineNo(int lineNo)
Set line number.
|
void |
setNextSibling(antlr.collections.AST ast) |
String |
toString() |
decode, encode, equals, equalsList, equalsListPartial, equalsTree, equalsTreePartial, findAll, findAllPartial, getColumn, getLine, getNumberOfChildren, getTokenNames, removeChildren, setVerboseStringConversion, toStringList, toStringTree, xmlSerialize, xmlSerializeNode, xmlSerializeRootClose, xmlSerializeRootOpen
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getNumberOfChildren, getText, getType
public DetailAstImpl()
public void initialize(antlr.Token tok)
initialize
in interface antlr.collections.AST
initialize
in class antlr.CommonASTWithHiddenTokens
public void initialize(antlr.collections.AST ast)
initialize
in interface antlr.collections.AST
initialize
in class antlr.CommonASTWithHiddenTokens
public void setFirstChild(antlr.collections.AST ast)
setFirstChild
in interface antlr.collections.AST
setFirstChild
in class antlr.BaseAST
public void setNextSibling(antlr.collections.AST ast)
setNextSibling
in interface antlr.collections.AST
setNextSibling
in class antlr.BaseAST
public void addPreviousSibling(DetailAST ast)
ast
- DetailAST object.public void addNextSibling(DetailAST ast)
ast
- DetailAST object.public void addChild(antlr.collections.AST ast)
addChild
in interface antlr.collections.AST
addChild
in class antlr.BaseAST
public int getChildCount()
DetailAST
getChildCount
in interface DetailAST
public int getChildCount(int type)
DetailAST
getChildCount
in interface DetailAST
type
- the token type to matchpublic DetailAST getParent()
DetailAST
public void setLineNo(int lineNo)
lineNo
- line number.public int getColumnNo()
DetailAST
getColumnNo
in interface DetailAST
public void setColumnNo(int columnNo)
columnNo
- column number.public DetailAST getLastChild()
DetailAST
getLastChild
in interface DetailAST
public boolean branchContains(int type)
DetailAST
branchContains
in interface DetailAST
type
- a TokenTypetype
.public DetailAST getPreviousSibling()
DetailAST
getPreviousSibling
in interface DetailAST
public DetailAST findFirstToken(int type)
DetailAST
findFirstToken
in interface DetailAST
type
- the token type to matchpublic String toString()
toString
in interface antlr.collections.AST
toString
in class antlr.BaseAST
public DetailAstImpl getNextSibling()
DetailAST
getNextSibling
in interface antlr.collections.AST
getNextSibling
in interface DetailAST
getNextSibling
in class antlr.BaseAST
public DetailAstImpl getFirstChild()
DetailAST
getFirstChild
in interface antlr.collections.AST
getFirstChild
in interface DetailAST
getFirstChild
in class antlr.BaseAST
public boolean hasChildren()
DetailAST
hasChildren
in interface DetailAST
true
if this AST has any children.Copyright © 2001–2020. All rights reserved.