Package org.apache.commons.jexl3.parser
Class ASTIdentifierAccess
java.lang.Object
org.apache.commons.jexl3.parser.SimpleNode
org.apache.commons.jexl3.parser.JexlNode
org.apache.commons.jexl3.parser.ASTIdentifierAccess
- All Implemented Interfaces:
Node
- Direct Known Subclasses:
ASTIdentifierAccessJxlt
,ASTIdentifierAccessSafe
Identifiers, variables and registers.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.commons.jexl3.parser.JexlNode
JexlNode.Constant<T>, JexlNode.Funcall, JexlNode.Info
-
Field Summary
FieldsFields inherited from class org.apache.commons.jexl3.parser.SimpleNode
id
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()
boolean
Whether this is a Jxlt based identifier.boolean
boolean
isSafe()
Whether this is a dot or a question-mark-dot aka safe-navigation access.jjtAccept
(ParserVisitor visitor, Object data) Accept the visitor.static Integer
Parse an identifier which must be of the form: 0|([1-9][0-9]*)(package private) void
setIdentifier
(String id) toString()
Methods inherited from class org.apache.commons.jexl3.parser.JexlNode
clearCache, getColumn, getLine, isConstant, isConstant, isLeftValue, isSafeLhs, isStrictOperator, jexlInfo, jjtSetFirstToken, jjtSetLastToken
Methods inherited from class org.apache.commons.jexl3.parser.SimpleNode
childrenAccept, dump, dumpOut, getId, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtGetValue, jjtOpen, jjtSetChildren, jjtSetParent, jjtSetValue, toString
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
name
-
identifier
-
-
Constructor Details
-
ASTIdentifierAccess
ASTIdentifierAccess(int id) -
ASTIdentifierAccess
ASTIdentifierAccess(Parser p, int id)
-
-
Method Details
-
setIdentifier
-
isGlobalVar
public boolean isGlobalVar()- Overrides:
isGlobalVar
in classJexlNode
- Returns:
- true if this node looks like a global var
-
isSafe
public boolean isSafe()Whether this is a dot or a question-mark-dot aka safe-navigation access.- Returns:
- true is ?., false if .
-
isExpression
public boolean isExpression()Whether this is a Jxlt based identifier.- Returns:
- true if `..${...}...`, false otherwise
-
parseIdentifier
Parse an identifier which must be of the form: 0|([1-9][0-9]*)- Parameters:
id
- the identifier- Returns:
- an integer or null
-
getIdentifier
-
getName
-
jjtAccept
Description copied from class:SimpleNode
Accept the visitor.- Specified by:
jjtAccept
in interfaceNode
- Overrides:
jjtAccept
in classSimpleNode
- Parameters:
visitor
- the visitordata
- contextual data- Returns:
- result of visit
-
toString
- Overrides:
toString
in classSimpleNode
-