public class ASTLiteral extends AbstractJavaTypeNode
parser
beginColumn, beginLine, childIndex, children, endColumn, endLine, firstToken, id, lastToken, parent
Constructor and Description |
---|
ASTLiteral(int id) |
ASTLiteral(JavaParser p,
int id) |
Modifier and Type | Method and Description |
---|---|
String |
getEscapedStringLiteral()
Tries to reconstruct the original string literal.
|
boolean |
isCharLiteral() |
boolean |
isDoubleLiteral()
Checks whether this literal describes a double.
|
boolean |
isFloatLiteral() |
boolean |
isIntLiteral() |
boolean |
isLongLiteral()
Checks whether this literal is a long integer.
|
boolean |
isSingleCharacterStringLiteral()
Returns true if this is a String literal with only one character.
|
boolean |
isStringLiteral() |
Object |
jjtAccept(JavaParserVisitor visitor,
Object data)
Accept the visitor.
|
void |
setCharLiteral() |
void |
setFloatLiteral() |
void |
setIntLiteral() |
void |
setStringLiteral() |
getType, setType
childrenAccept, comment, comment, getScope, jjtClose, jjtOpen, setScope, toString
appendElement, findChildNodesWithXPath, findChildrenOfType, findDescendantsOfType, findDescendantsOfType, getAsDocument, getBeginColumn, getBeginLine, getDataFlowNode, getEndColumn, getEndLine, getFirstChildOfType, getFirstDescendantOfType, getFirstParentOfType, getImage, getNthParent, getParentsOfType, getUserData, hasDecendantOfAnyType, hasDescendantMatchingXPath, hasDescendantOfType, hasImageEqualTo, isFindBoundary, isSingleLine, jjtAddChild, jjtGetChild, jjtGetChildIndex, jjtGetFirstToken, jjtGetId, jjtGetLastToken, jjtGetNumChildren, jjtGetParent, jjtSetChildIndex, jjtSetFirstToken, jjtSetLastToken, jjtSetParent, setDataFlowNode, setImage, setUserData, testingOnly__setBeginColumn, testingOnly__setBeginLine, testingOnly__setEndColumn, testingOnly__setEndLine
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
findChildNodesWithXPath, findChildrenOfType, findDescendantsOfType, findDescendantsOfType, getAsDocument, getBeginColumn, getBeginLine, getDataFlowNode, getEndColumn, getEndLine, getFirstChildOfType, getFirstDescendantOfType, getFirstParentOfType, getImage, getNthParent, getParentsOfType, getUserData, hasDescendantMatchingXPath, hasDescendantOfType, hasImageEqualTo, isFindBoundary, jjtAddChild, jjtClose, jjtGetChild, jjtGetChildIndex, jjtGetId, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetChildIndex, jjtSetParent, setDataFlowNode, setImage, setUserData
public ASTLiteral(int id)
public ASTLiteral(JavaParser p, int id)
public Object jjtAccept(JavaParserVisitor visitor, Object data)
jjtAccept
in interface JavaNode
jjtAccept
in class AbstractJavaNode
public void setIntLiteral()
public boolean isIntLiteral()
public boolean isLongLiteral()
true
if this literal is a longpublic void setFloatLiteral()
public boolean isFloatLiteral()
public boolean isDoubleLiteral()
true
if this literal is a double.public void setCharLiteral()
public boolean isCharLiteral()
public void setStringLiteral()
public boolean isStringLiteral()
public String getEscapedStringLiteral()
public boolean isSingleCharacterStringLiteral()
Copyright © 2002-2017 PMD. All Rights Reserved.