Package org.apache.commons.jexl3
Class JexlException.Variable
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.apache.commons.jexl3.JexlException
org.apache.commons.jexl3.JexlException.Variable
- All Implemented Interfaces:
Serializable
- Enclosing class:
- JexlException
Thrown when a variable is unknown.
- Since:
- 3.0
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.commons.jexl3.JexlException
JexlException.Ambiguous, JexlException.Annotation, JexlException.Assignment, JexlException.Break, JexlException.Cancel, JexlException.Continue, JexlException.Feature, JexlException.Method, JexlException.Operator, JexlException.Parsing, JexlException.Property, JexlException.Return, JexlException.StackOverflow, JexlException.Throw, JexlException.Tokenization, JexlException.TryFailed, JexlException.Variable, JexlException.VariableIssue -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final JexlException.VariableIssueUndefined variable flag.private static final long -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringAccesses the detailed message.Gets the variable namebooleanTests whether the variable causing an error is undefined or evaluated as null.Methods inherited from class org.apache.commons.jexl3.JexlException
annotationError, clean, clean, detailedInfo, errorAt, getDetail, getInfo, getInfo, getMessage, info, merge, methodError, methodError, methodSignature, operatorError, parserError, propertyError, propertyError, sliceSource, tryFailed, unwrap, variableError, variableErrorMethods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
serialVersionUID
private static final long serialVersionUID- See Also:
-
issue
Undefined variable flag.
-
-
Constructor Details
-
Variable
Creates a new Variable exception instance.- Parameters:
node- The offending ASTnodevar- The unknown variableundef- whether the variable is undefined or evaluated as null
-
Variable
Creates a new Variable exception instance.- Parameters:
node- The offending ASTnodevar- The unknown variablevi- The variable issue
-
-
Method Details
-
detailedMessage
Description copied from class:JexlExceptionAccesses the detailed message.- Overrides:
detailedMessagein classJexlException- Returns:
- The message
-
getVariable
Gets the variable name- Returns:
- The variable name
-
isUndefined
public boolean isUndefined()Tests whether the variable causing an error is undefined or evaluated as null.- Returns:
- true if undefined, false otherwise
-