Package org.apache.cayenne.exp.parser
Class ExpressionParser
java.lang.Object
org.apache.cayenne.exp.parser.ExpressionParser
- All Implemented Interfaces:
ExpressionParserConstants
,ExpressionParserTreeConstants
public class ExpressionParser
extends Object
implements ExpressionParserTreeConstants, ExpressionParserConstants
Parser of Cayenne Expressions.
- Since:
- 1.1
-
Field Summary
Modifier and TypeFieldDescriptionNext token.protected JJTExpressionParserState
Current token.Generated Token Manager.Fields inherited from interface org.apache.cayenne.exp.parser.ExpressionParserConstants
ABS, ASTERISK, AVG, CONCAT, COUNT, CURRENT_DATE, CURRENT_TIME, CURRENT_TIMESTAMP, DAY, DAY_OF_MONTH, DAY_OF_WEEK, DAY_OF_YEAR, DEC_DIGITS, DEC_FLT, DEFAULT, DIGIT, DISTINCT, DOLLAR_SIGN, DOUBLE_QUOTED_STRING, EOF, ESC, EXPONENT, FALSE, FLOAT_LITERAL, FLT_SUFF, FUNCTION, HOUR, IDENTIFIER, INT_LITERAL, LENGTH, LETTER, LOCATE, LOWER, MAX, MIN, MINUTE, MOD, MONTH, NULL, OPERATOR, PROPERTY_PATH, SECOND, SINGLE_QUOTED_STRING, SQRT, STRING_ESC, SUBSTRING, SUM, tokenImage, TRIM, TRUE, UPPER, WEEK, WithinDoubleQuoteLiteral, WithinSingleQuoteLiteral, YEAR
Fields inherited from interface org.apache.cayenne.exp.parser.ExpressionParserTreeConstants
JJTABS, JJTADD, JJTAND, JJTASTERISK, JJTAVG, JJTBETWEEN, JJTBITWISEAND, JJTBITWISELEFTSHIFT, JJTBITWISENOT, JJTBITWISEOR, JJTBITWISERIGHTSHIFT, JJTBITWISEXOR, JJTCONCAT, JJTCOUNT, JJTCURRENTDATE, JJTCURRENTTIME, JJTCURRENTTIMESTAMP, JJTCUSTOMFUNCTION, JJTCUSTOMOPERATOR, JJTDBIDPATH, JJTDBPATH, JJTDISTINCT, JJTDIVIDE, JJTENUM, JJTEQUAL, JJTEXTRACT, JJTFALSE, JJTGREATER, JJTGREATEROREQUAL, JJTIN, JJTLENGTH, JJTLESS, JJTLESSOREQUAL, JJTLIKE, JJTLIKEIGNORECASE, JJTLIST, JJTLOCATE, JJTLOWER, JJTMAX, JJTMIN, JJTMOD, JJTMULTIPLY, JJTNAMEDPARAMETER, JJTNEGATE, jjtNodeName, JJTNOT, JJTNOTBETWEEN, JJTNOTEQUAL, JJTNOTIN, JJTNOTLIKE, JJTNOTLIKEIGNORECASE, JJTOBJPATH, JJTOR, JJTSCALAR, JJTSQRT, JJTSUBSTRING, JJTSUBTRACT, JJTSUM, JJTTRIM, JJTTRUE, JJTUPPER, JJTVOID
-
Constructor Summary
ConstructorDescriptionExpressionParser
(InputStream stream) Constructor with InputStream.ExpressionParser
(InputStream stream, String encoding) Constructor with InputStream and supplied encodingExpressionParser
(Reader stream) Constructor.Constructor with generated Token Manager. -
Method Summary
Modifier and TypeMethodDescriptionfinal void
abs()
final void
final void
final void
final void
asterisk()
final void
avg()
final void
final void
final void
final void
final void
concat()
final void
final void
count()
final void
final void
final void
final void
final void
final void
final void
final void
Disable tracing.final void
distinct()
final void
Enable tracing.final Expression
final void
final void
Generate ParseException.final Token
Get the next Token.final Token
getToken
(int index) Get the specific Token.final void
length()
final void
locate()
final void
lower()
final void
max()
final void
min()
final void
mod()
final void
final void
final void
final void
final void
final void
final void
final void
final void
final Token
void
ReInit
(InputStream stream) Reinitialise.void
ReInit
(InputStream stream, String encoding) Reinitialise.void
Reinitialise.void
Reinitialise.final void
final void
final void
final void
final void
final void
sqrt()
final void
final void
final void
final void
final void
sum()
final boolean
Trace enabled.final void
trim()
final void
upper()
-
Field Details
-
jjtree
-
token_source
Generated Token Manager. -
token
Current token. -
jj_nt
Next token.
-
-
Constructor Details
-
ExpressionParser
Constructor with InputStream. -
ExpressionParser
Constructor with InputStream and supplied encoding -
ExpressionParser
Constructor. -
ExpressionParser
Constructor with generated Token Manager.
-
-
Method Details
-
expression
- Throws:
ParseException
-
orCondition
- Throws:
ParseException
-
andCondition
- Throws:
ParseException
-
notCondition
- Throws:
ParseException
-
simpleCondition
- Throws:
ParseException
-
simpleNotCondition
- Throws:
ParseException
-
scalarCommaList
- Throws:
ParseException
-
conditionExpression
- Throws:
ParseException
-
stringParameter
- Throws:
ParseException
-
stringLiteral
- Throws:
ParseException
-
stringExpression
- Throws:
ParseException
-
scalarExpression
- Throws:
ParseException
-
scalarConstExpression
- Throws:
ParseException
-
numericExpression
- Throws:
ParseException
-
bitwiseOr
- Throws:
ParseException
-
bitwiseXor
- Throws:
ParseException
-
bitwiseAnd
- Throws:
ParseException
-
bitwiseShift
- Throws:
ParseException
-
arithmeticExp
- Throws:
ParseException
-
multiplySubtractExp
- Throws:
ParseException
-
numericTermExt
- Throws:
ParseException
-
numericTerm
- Throws:
ParseException
-
numericPrimary
- Throws:
ParseException
-
functionsReturningStrings
- Throws:
ParseException
-
customFunction
- Throws:
ParseException
-
customOperator
- Throws:
ParseException
-
concat
- Throws:
ParseException
-
substring
- Throws:
ParseException
-
trim
- Throws:
ParseException
-
lower
- Throws:
ParseException
-
upper
- Throws:
ParseException
-
functionsReturningNumerics
- Throws:
ParseException
-
length
- Throws:
ParseException
-
locate
- Throws:
ParseException
-
abs
- Throws:
ParseException
-
sqrt
- Throws:
ParseException
-
mod
- Throws:
ParseException
-
aggregateExpression
- Throws:
ParseException
-
asterisk
- Throws:
ParseException
-
count
- Throws:
ParseException
-
avg
- Throws:
ParseException
-
max
- Throws:
ParseException
-
min
- Throws:
ParseException
-
sum
- Throws:
ParseException
-
dateTimeFunction
- Throws:
ParseException
-
currentDate
- Throws:
ParseException
-
currentTime
- Throws:
ParseException
-
currentTimestamp
- Throws:
ParseException
-
dateTimeExtractingFunction
- Throws:
ParseException
-
distinct
- Throws:
ParseException
-
namedParameter
- Throws:
ParseException
-
pathExpression
- Throws:
ParseException
-
pathToken
- Throws:
ParseException
-
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
ReInit
Reinitialise. -
getNextToken
Get the next Token. -
getToken
Get the specific Token. -
generateParseException
Generate ParseException. -
trace_enabled
public final boolean trace_enabled()Trace enabled. -
enable_tracing
public final void enable_tracing()Enable tracing. -
disable_tracing
public final void disable_tracing()Disable tracing.
-