Class OgnlParser

java.lang.Object
org.apache.commons.ognl.OgnlParser
All Implemented Interfaces:
OgnlParserConstants, OgnlParserTreeConstants

public class OgnlParser extends Object implements OgnlParserTreeConstants, OgnlParserConstants
OgnlParser is a JavaCC parser class; it translates OGNL expressions into abstract syntax trees (ASTs) that can then be interpreted by the getValue and setValue methods.
  • Field Details

    • jjtree

      protected JJTOgnlParserState jjtree
    • token_source

      public OgnlParserTokenManager token_source
      Generated Token Manager.
    • jj_input_stream

      JavaCharStream jj_input_stream
    • token

      public Token token
      Current token.
    • jj_nt

      public Token jj_nt
      Next token.
    • jj_ntk

      private int jj_ntk
    • jj_scanpos

      private Token jj_scanpos
    • jj_lastpos

      private Token jj_lastpos
    • jj_la

      private int jj_la
    • jj_gen

      private int jj_gen
    • jj_la1

      private final int[] jj_la1
    • jj_la1_0

      private static int[] jj_la1_0
    • jj_la1_1

      private static int[] jj_la1_1
    • jj_la1_2

      private static int[] jj_la1_2
    • jj_2_rtns

      private final OgnlParser.JJCalls[] jj_2_rtns
    • jj_rescan

      private boolean jj_rescan
    • jj_gc

      private int jj_gc
    • jj_ls

      private static final OgnlParser.LookaheadSuccess jj_ls
    • jj_expentries

      private List<int[]> jj_expentries
    • jj_expentry

      private int[] jj_expentry
    • jj_kind

      private int jj_kind
    • jj_lasttokens

      private int[] jj_lasttokens
    • jj_endpos

      private int jj_endpos
    • trace_enabled

      private boolean trace_enabled
  • Constructor Details

    • OgnlParser

      public OgnlParser(InputStream stream)
      Constructor with InputStream.
    • OgnlParser

      public OgnlParser(InputStream stream, String encoding)
      Constructor with InputStream and supplied encoding
    • OgnlParser

      public OgnlParser(Reader stream)
      Constructor.
    • OgnlParser

      public OgnlParser(OgnlParserTokenManager tm)
      Constructor with generated Token Manager.
  • Method Details

    • topLevelExpression

      public final Node topLevelExpression() throws ParseException
      This is the top-level construct of OGNL.
      Throws:
      ParseException
    • expression

      public final void expression() throws ParseException
      Throws:
      ParseException
    • assignmentExpression

      public final void assignmentExpression() throws ParseException
      Throws:
      ParseException
    • conditionalTestExpression

      public final void conditionalTestExpression() throws ParseException
      Throws:
      ParseException
    • logicalOrExpression

      public final void logicalOrExpression() throws ParseException
      Throws:
      ParseException
    • logicalAndExpression

      public final void logicalAndExpression() throws ParseException
      Throws:
      ParseException
    • inclusiveOrExpression

      public final void inclusiveOrExpression() throws ParseException
      Throws:
      ParseException
    • exclusiveOrExpression

      public final void exclusiveOrExpression() throws ParseException
      Throws:
      ParseException
    • andExpression

      public final void andExpression() throws ParseException
      Throws:
      ParseException
    • equalityExpression

      public final void equalityExpression() throws ParseException
      Throws:
      ParseException
    • relationalExpression

      public final void relationalExpression() throws ParseException
      Throws:
      ParseException
    • shiftExpression

      public final void shiftExpression() throws ParseException
      Throws:
      ParseException
    • additiveExpression

      public final void additiveExpression() throws ParseException
      Throws:
      ParseException
    • multiplicativeExpression

      public final void multiplicativeExpression() throws ParseException
      Throws:
      ParseException
    • unaryExpression

      public final void unaryExpression() throws ParseException
      Throws:
      ParseException
    • primaryExpression

      public final void primaryExpression() throws ParseException
      Throws:
      ParseException
    • keyValueExpression

      public final void keyValueExpression() throws ParseException
      Throws:
      ParseException
    • staticReference

      public final void staticReference() throws ParseException
      Throws:
      ParseException
    • classReference

      public final String classReference() throws ParseException
      Throws:
      ParseException
    • className

      public final String className() throws ParseException
      Throws:
      ParseException
    • constructorCall

      public final void constructorCall() throws ParseException
      Throws:
      ParseException
    • propertyName

      public final void propertyName() throws ParseException
      Throws:
      ParseException
    • staticMethodCall

      public final void staticMethodCall(String className) throws ParseException
      Throws:
      ParseException
    • methodCall

      public final void methodCall() throws ParseException
      Throws:
      ParseException
    • projection

      public final void projection() throws ParseException
      Apply an expression to all elements of a collection, creating a new collection as the result.
      Throws:
      ParseException
    • selection

      public final void selection() throws ParseException
      Throws:
      ParseException
    • selectAll

      public final void selectAll() throws ParseException
      Apply a boolean expression to all elements of a collection, creating a new collection containing those elements for which the expression returned true.
      Throws:
      ParseException
    • selectFirst

      public final void selectFirst() throws ParseException
      Apply a boolean expression to all elements of a collection, creating a new collection containing those elements for the first element for which the expression returned true.
      Throws:
      ParseException
    • selectLast

      public final void selectLast() throws ParseException
      Apply a boolean expression to all elements of a collection, creating a new collection containing those elements for the first element for which the expression returned true.
      Throws:
      ParseException
    • index

      public final void index() throws ParseException
      Throws:
      ParseException
    • jj_2_1

      private boolean jj_2_1(int xla)
    • jj_2_2

      private boolean jj_2_2(int xla)
    • jj_2_3

      private boolean jj_2_3(int xla)
    • jj_2_4

      private boolean jj_2_4(int xla)
    • jj_2_5

      private boolean jj_2_5(int xla)
    • jj_2_6

      private boolean jj_2_6(int xla)
    • jj_2_7

      private boolean jj_2_7(int xla)
    • jj_2_8

      private boolean jj_2_8(int xla)
    • jj_2_9

      private boolean jj_2_9(int xla)
    • jj_2_10

      private boolean jj_2_10(int xla)
    • jj_2_11

      private boolean jj_2_11(int xla)
    • jj_2_12

      private boolean jj_2_12(int xla)
    • jj_2_13

      private boolean jj_2_13(int xla)
    • jj_2_14

      private boolean jj_2_14(int xla)
    • jj_2_15

      private boolean jj_2_15(int xla)
    • jj_2_16

      private boolean jj_2_16(int xla)
    • jj_3R_primaryExpression_274_9_57

      private boolean jj_3R_primaryExpression_274_9_57()
    • jj_3R_staticMethodCall_371_5_25

      private boolean jj_3R_staticMethodCall_371_5_25()
    • jj_3R_conditionalTestExpression_86_5_34

      private boolean jj_3R_conditionalTestExpression_86_5_34()
    • jj_3_7

      private boolean jj_3_7()
    • jj_3_6

      private boolean jj_3_6()
    • jj_3_5

      private boolean jj_3_5()
    • jj_3R_assignmentExpression_80_5_27

      private boolean jj_3R_assignmentExpression_80_5_27()
    • jj_3_4

      private boolean jj_3_4()
    • jj_3R_propertyName_364_5_65

      private boolean jj_3R_propertyName_364_5_65()
    • jj_3R_additiveExpression_174_5_43

      private boolean jj_3R_additiveExpression_174_5_43()
    • jj_3R_primaryExpression_264_9_56

      private boolean jj_3R_primaryExpression_264_9_56()
    • jj_3R_primaryExpression_262_9_55

      private boolean jj_3R_primaryExpression_262_9_55()
    • jj_3R_primaryExpression_260_9_54

      private boolean jj_3R_primaryExpression_260_9_54()
    • jj_3R_expression_74_5_31

      private boolean jj_3R_expression_74_5_31()
    • jj_3_13

      private boolean jj_3_13()
    • jj_3R_primaryExpression_257_9_53

      private boolean jj_3R_primaryExpression_257_9_53()
    • jj_3R_constructorCall_336_23_26

      private boolean jj_3R_constructorCall_336_23_26()
    • jj_3R_primaryExpression_256_5_52

      private boolean jj_3R_primaryExpression_256_5_52()
    • jj_3R_shiftExpression_160_5_42

      private boolean jj_3R_shiftExpression_160_5_42()
    • jj_3_12

      private boolean jj_3_12()
    • jj_3_11

      private boolean jj_3_11()
    • jj_3R_index_432_5_67

      private boolean jj_3R_index_432_5_67()
    • jj_3_2

      private boolean jj_3_2()
    • jj_3R_index_430_5_66

      private boolean jj_3R_index_430_5_66()
    • jj_3R_index_430_5_64

      private boolean jj_3R_index_430_5_64()
    • jj_3_1

      private boolean jj_3_1()
    • jj_3R_constructorCall_333_5_23

      private boolean jj_3R_constructorCall_333_5_23()
    • jj_3R_relationalExpression_140_5_41

      private boolean jj_3R_relationalExpression_140_5_41()
    • jj_3R_selectLast_425_5_30

      private boolean jj_3R_selectLast_425_5_30()
    • jj_3R_className_322_5_32

      private boolean jj_3R_className_322_5_32()
    • jj_3R_navigationChain_226_5_51

      private boolean jj_3R_navigationChain_226_5_51()
    • jj_3R_selectFirst_416_5_29

      private boolean jj_3R_selectFirst_416_5_29()
    • jj_3R_equalityExpression_128_5_40

      private boolean jj_3R_equalityExpression_128_5_40()
    • jj_3R_classReference_314_5_33

      private boolean jj_3R_classReference_314_5_33()
    • jj_3R_primaryExpression_279_39_63

      private boolean jj_3R_primaryExpression_279_39_63()
    • jj_3R_selectAll_407_5_28

      private boolean jj_3R_selectAll_407_5_28()
    • jj_3R_unaryExpression_212_9_50

      private boolean jj_3R_unaryExpression_212_9_50()
    • jj_3R_andExpression_121_5_39

      private boolean jj_3R_andExpression_121_5_39()
    • jj_3_10

      private boolean jj_3_10()
    • jj_3R_primaryExpression_287_29_24

      private boolean jj_3R_primaryExpression_287_29_24()
    • jj_3R_unaryExpression_210_9_49

      private boolean jj_3R_unaryExpression_210_9_49()
    • jj_3R_unaryExpression_208_9_48

      private boolean jj_3R_unaryExpression_208_9_48()
    • jj_3_16

      private boolean jj_3_16()
    • jj_3R_unaryExpression_206_9_47

      private boolean jj_3R_unaryExpression_206_9_47()
    • jj_3_15

      private boolean jj_3_15()
    • jj_3R_exclusiveOrExpression_114_5_38

      private boolean jj_3R_exclusiveOrExpression_114_5_38()
    • jj_3R_unaryExpression_204_9_46

      private boolean jj_3R_unaryExpression_204_9_46()
    • jj_3_14

      private boolean jj_3_14()
    • jj_3R_staticReference_301_5_62

      private boolean jj_3R_staticReference_301_5_62()
    • jj_3R_unaryExpression_203_5_45

      private boolean jj_3R_unaryExpression_203_5_45()
    • jj_3R_inclusiveOrExpression_107_5_37

      private boolean jj_3R_inclusiveOrExpression_107_5_37()
    • jj_3R_projection_389_5_22

      private boolean jj_3R_projection_389_5_22()
    • jj_3_9

      private boolean jj_3_9()
    • jj_3R_logicalAndExpression_100_5_36

      private boolean jj_3R_logicalAndExpression_100_5_36()
    • jj_3R_primaryExpression_285_9_61

      private boolean jj_3R_primaryExpression_285_9_61()
    • jj_3R_primaryExpression_283_9_60

      private boolean jj_3R_primaryExpression_283_9_60()
    • jj_3R_primaryExpression_281_9_59

      private boolean jj_3R_primaryExpression_281_9_59()
    • jj_3_3

      private boolean jj_3_3()
    • jj_3R_methodCall_379_5_21

      private boolean jj_3R_methodCall_379_5_21()
    • jj_3R_primaryExpression_279_9_58

      private boolean jj_3R_primaryExpression_279_9_58()
    • jj_3R_logicalOrExpression_93_5_35

      private boolean jj_3R_logicalOrExpression_93_5_35()
    • jj_3R_multiplicativeExpression_186_5_44

      private boolean jj_3R_multiplicativeExpression_186_5_44()
    • jj_3_8

      private boolean jj_3_8()
    • jj_la1_init_0

      private static void jj_la1_init_0()
    • jj_la1_init_1

      private static void jj_la1_init_1()
    • jj_la1_init_2

      private static void jj_la1_init_2()
    • ReInit

      public void ReInit(InputStream stream)
      Reinitialise.
    • ReInit

      public void ReInit(InputStream stream, String encoding)
      Reinitialise.
    • ReInit

      public void ReInit(Reader stream)
      Reinitialise.
    • ReInit

      public void ReInit(OgnlParserTokenManager tm)
      Reinitialise.
    • jj_consume_token

      private Token jj_consume_token(int kind) throws ParseException
      Throws:
      ParseException
    • jj_scan_token

      private boolean jj_scan_token(int kind)
    • getNextToken

      public final Token getNextToken()
      Get the next Token.
    • getToken

      public final Token getToken(int index)
      Get the specific Token.
    • jj_ntk_f

      private int jj_ntk_f()
    • jj_add_error_token

      private void jj_add_error_token(int kind, int pos)
    • generateParseException

      public ParseException 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.
    • jj_rescan_token

      private void jj_rescan_token()
    • jj_save

      private void jj_save(int index, int xla)