http://git-wip-us.apache.org/repos/asf/struts/blob/775c82a7/plugins/embeddedjsp/src/main/java/org/apache/struts2/el/parser/ELParser.java ---------------------------------------------------------------------- diff --git a/plugins/embeddedjsp/src/main/java/org/apache/struts2/el/parser/ELParser.java b/plugins/embeddedjsp/src/main/java/org/apache/struts2/el/parser/ELParser.java index 6cd2847..d8dd5dd 100644 --- a/plugins/embeddedjsp/src/main/java/org/apache/struts2/el/parser/ELParser.java +++ b/plugins/embeddedjsp/src/main/java/org/apache/struts2/el/parser/ELParser.java @@ -1,10 +1,13 @@ /* Generated By:JJTree&JavaCC: Do not edit this line. ELParser.java */ package org.apache.struts2.el.parser; -import java.io.StringReader; + import javax.el.ELException; -public class ELParser/*@bgen(jjtree)*/implements ELParserTreeConstants, ELParserConstants {/*@bgen(jjtree)*/ - protected JJTELParserState jjtree = new JJTELParserState();public static Node parse(String ref) throws ELException - { +import java.io.StringReader; + +public class ELParser/*@bgen(jjtree)*/ implements ELParserTreeConstants, ELParserConstants {/*@bgen(jjtree)*/ + protected JJTELParserState jjtree = new JJTELParserState(); + + public static Node parse(String ref) throws ELException { try { return (new ELParser(new StringReader(ref))).CompositeExpression(); } catch (ParseException pe) { @@ -12,2179 +15,2451 @@ public class ELParser/*@bgen(jjtree)*/implements ELParserTreeConstants, ELParser } } -/* - * CompositeExpression - * Allow most flexible parsing, restrict by examining - * type of returned node - */ - final public AstCompositeExpression CompositeExpression() throws ParseException { + /* + * CompositeExpression + * Allow most flexible parsing, restrict by examining + * type of returned node + */ + final public AstCompositeExpression CompositeExpression() throws ParseException { /*@bgen(jjtree) CompositeExpression */ - AstCompositeExpression jjtn000 = new AstCompositeExpression(JJTCOMPOSITEEXPRESSION); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000); - try { - label_1: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case LITERAL_EXPRESSION: - case START_DYNAMIC_EXPRESSION: - case START_DEFERRED_EXPRESSION: - ; - break; - default: - jj_la1[0] = jj_gen; - break label_1; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case START_DEFERRED_EXPRESSION: - DeferredExpression(); - break; - case START_DYNAMIC_EXPRESSION: - DynamicExpression(); - break; - case LITERAL_EXPRESSION: - LiteralExpression(); - break; - default: - jj_la1[1] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - jj_consume_token(0); - jjtree.closeNodeScope(jjtn000, true); - jjtc000 = false; - {if (true) return jjtn000;} - } catch (Throwable jjte000) { - if (jjtc000) { - jjtree.clearNodeScope(jjtn000); - jjtc000 = false; - } else { - jjtree.popNode(); - } - if (jjte000 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte000;} - } - if (jjte000 instanceof ParseException) { - {if (true) throw (ParseException)jjte000;} - } - {if (true) throw (Error)jjte000;} - } finally { - if (jjtc000) { - jjtree.closeNodeScope(jjtn000, true); - } - } - throw new Error("Missing return statement in function"); - } - -/* - * LiteralExpression - * Non-EL Expression blocks - */ - final public void LiteralExpression() throws ParseException { + AstCompositeExpression jjtn000 = new AstCompositeExpression(JJTCOMPOSITEEXPRESSION); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + try { + label_1: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case LITERAL_EXPRESSION: + case START_DYNAMIC_EXPRESSION: + case START_DEFERRED_EXPRESSION: + ; + break; + default: + jj_la1[0] = jj_gen; + break label_1; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case START_DEFERRED_EXPRESSION: + DeferredExpression(); + break; + case START_DYNAMIC_EXPRESSION: + DynamicExpression(); + break; + case LITERAL_EXPRESSION: + LiteralExpression(); + break; + default: + jj_la1[1] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + jj_consume_token(0); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + { + if (true) return jjtn000; + } + } catch (Throwable jjte000) { + if (jjtc000) { + jjtree.clearNodeScope(jjtn000); + jjtc000 = false; + } else { + jjtree.popNode(); + } + if (jjte000 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte000; + } + } + if (jjte000 instanceof ParseException) { + { + if (true) throw (ParseException) jjte000; + } + } + { + if (true) throw (Error) jjte000; + } + } finally { + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + throw new Error("Missing return statement in function"); + } + + /* + * LiteralExpression + * Non-EL Expression blocks + */ + final public void LiteralExpression() throws ParseException { /*@bgen(jjtree) LiteralExpression */ - AstLiteralExpression jjtn000 = new AstLiteralExpression(JJTLITERALEXPRESSION); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000);Token t = null; - try { - t = jj_consume_token(LITERAL_EXPRESSION); - jjtree.closeNodeScope(jjtn000, true); - jjtc000 = false; - jjtn000.setImage(t.image); - } finally { - if (jjtc000) { - jjtree.closeNodeScope(jjtn000, true); - } - } - } - -/* - * DeferredExpression - * #{..} Expressions - */ - final public void DeferredExpression() throws ParseException { + AstLiteralExpression jjtn000 = new AstLiteralExpression(JJTLITERALEXPRESSION); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; + try { + t = jj_consume_token(LITERAL_EXPRESSION); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); + } finally { + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * DeferredExpression + * #{..} Expressions + */ + final public void DeferredExpression() throws ParseException { /*@bgen(jjtree) DeferredExpression */ - AstDeferredExpression jjtn000 = new AstDeferredExpression(JJTDEFERREDEXPRESSION); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000); - try { - jj_consume_token(START_DEFERRED_EXPRESSION); - Expression(); - jj_consume_token(END_EXPRESSION); - } catch (Throwable jjte000) { - if (jjtc000) { - jjtree.clearNodeScope(jjtn000); - jjtc000 = false; - } else { - jjtree.popNode(); - } - if (jjte000 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte000;} - } - if (jjte000 instanceof ParseException) { - {if (true) throw (ParseException)jjte000;} - } - {if (true) throw (Error)jjte000;} - } finally { - if (jjtc000) { - jjtree.closeNodeScope(jjtn000, true); - } - } - } - -/* - * DynamicExpression - * ${..} Expressions - */ - final public void DynamicExpression() throws ParseException { + AstDeferredExpression jjtn000 = new AstDeferredExpression(JJTDEFERREDEXPRESSION); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + try { + jj_consume_token(START_DEFERRED_EXPRESSION); + Expression(); + jj_consume_token(END_EXPRESSION); + } catch (Throwable jjte000) { + if (jjtc000) { + jjtree.clearNodeScope(jjtn000); + jjtc000 = false; + } else { + jjtree.popNode(); + } + if (jjte000 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte000; + } + } + if (jjte000 instanceof ParseException) { + { + if (true) throw (ParseException) jjte000; + } + } + { + if (true) throw (Error) jjte000; + } + } finally { + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * DynamicExpression + * ${..} Expressions + */ + final public void DynamicExpression() throws ParseException { /*@bgen(jjtree) DynamicExpression */ - AstDynamicExpression jjtn000 = new AstDynamicExpression(JJTDYNAMICEXPRESSION); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000); - try { - jj_consume_token(START_DYNAMIC_EXPRESSION); - Expression(); - jj_consume_token(END_EXPRESSION); - } catch (Throwable jjte000) { - if (jjtc000) { - jjtree.clearNodeScope(jjtn000); - jjtc000 = false; - } else { - jjtree.popNode(); - } - if (jjte000 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte000;} - } - if (jjte000 instanceof ParseException) { - {if (true) throw (ParseException)jjte000;} - } - {if (true) throw (Error)jjte000;} - } finally { - if (jjtc000) { - jjtree.closeNodeScope(jjtn000, true); - } - } - } - -/* - * Expression - * EL Expression Language Root, goes to Choice - */ - final public void Expression() throws ParseException { - Choice(); - } - -/* - * Choice - * For Choice markup a ? b : c, then Or - */ - final public void Choice() throws ParseException { - Or(); - label_2: - while (true) { - if (jj_2_1(3)) { - ; - } else { - break label_2; - } - jj_consume_token(QUESTIONMARK); - Choice(); - jj_consume_token(COLON); - AstChoice jjtn001 = new AstChoice(JJTCHOICE); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); - try { + AstDynamicExpression jjtn000 = new AstDynamicExpression(JJTDYNAMICEXPRESSION); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + try { + jj_consume_token(START_DYNAMIC_EXPRESSION); + Expression(); + jj_consume_token(END_EXPRESSION); + } catch (Throwable jjte000) { + if (jjtc000) { + jjtree.clearNodeScope(jjtn000); + jjtc000 = false; + } else { + jjtree.popNode(); + } + if (jjte000 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte000; + } + } + if (jjte000 instanceof ParseException) { + { + if (true) throw (ParseException) jjte000; + } + } + { + if (true) throw (Error) jjte000; + } + } finally { + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * Expression + * EL Expression Language Root, goes to Choice + */ + final public void Expression() throws ParseException { Choice(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} - } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 3); - } - } - } - } - -/* - * Or - * For 'or' '||', then And - */ - final public void Or() throws ParseException { - And(); - label_3: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case OR0: - case OR1: - ; - break; - default: - jj_la1[2] = jj_gen; - break label_3; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case OR0: - jj_consume_token(OR0); - break; - case OR1: - jj_consume_token(OR1); - break; - default: - jj_la1[3] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstOr jjtn001 = new AstOr(JJTOR); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); - try { + } + + /* + * Choice + * For Choice markup a ? b : c, then Or + */ + final public void Choice() throws ParseException { + Or(); + label_2: + while (true) { + if (jj_2_1(3)) { + ; + } else { + break label_2; + } + jj_consume_token(QUESTIONMARK); + Choice(); + jj_consume_token(COLON); + AstChoice jjtn001 = new AstChoice(JJTCHOICE); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Choice(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 3); + } + } + } + } + + /* + * Or + * For 'or' '||', then And + */ + final public void Or() throws ParseException { And(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} - } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - } - } - -/* - * And - * For 'and' '&&', then Equality - */ - final public void And() throws ParseException { - Equality(); - label_4: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case AND0: - case AND1: - ; - break; - default: - jj_la1[4] = jj_gen; - break label_4; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case AND0: - jj_consume_token(AND0); - break; - case AND1: - jj_consume_token(AND1); - break; - default: - jj_la1[5] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstAnd jjtn001 = new AstAnd(JJTAND); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); - try { + label_3: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case OR0: + case OR1: + ; + break; + default: + jj_la1[2] = jj_gen; + break label_3; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case OR0: + jj_consume_token(OR0); + break; + case OR1: + jj_consume_token(OR1); + break; + default: + jj_la1[3] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstOr jjtn001 = new AstOr(JJTOR); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + And(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + } + } + + /* + * And + * For 'and' '&&', then Equality + */ + final public void And() throws ParseException { Equality(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} - } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - } - } - -/* - * Equality - * For '==' 'eq' '!=' 'ne', then Compare - */ - final public void Equality() throws ParseException { - Compare(); - label_5: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case EQ0: - case EQ1: - case NE0: - case NE1: - ; - break; - default: - jj_la1[6] = jj_gen; - break label_5; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case EQ0: - case EQ1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case EQ0: - jj_consume_token(EQ0); - break; - case EQ1: - jj_consume_token(EQ1); - break; - default: - jj_la1[7] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstEqual jjtn001 = new AstEqual(JJTEQUAL); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); + label_4: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case AND0: + case AND1: + ; + break; + default: + jj_la1[4] = jj_gen; + break label_4; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case AND0: + jj_consume_token(AND0); + break; + case AND1: + jj_consume_token(AND1); + break; + default: + jj_la1[5] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstAnd jjtn001 = new AstAnd(JJTAND); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Equality(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + } + } + + /* + * Equality + * For '==' 'eq' '!=' 'ne', then Compare + */ + final public void Equality() throws ParseException { + Compare(); + label_5: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case EQ0: + case EQ1: + case NE0: + case NE1: + ; + break; + default: + jj_la1[6] = jj_gen; + break label_5; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case EQ0: + case EQ1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case EQ0: + jj_consume_token(EQ0); + break; + case EQ1: + jj_consume_token(EQ1); + break; + default: + jj_la1[7] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstEqual jjtn001 = new AstEqual(JJTEQUAL); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Compare(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + break; + case NE0: + case NE1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case NE0: + jj_consume_token(NE0); + break; + case NE1: + jj_consume_token(NE1); + break; + default: + jj_la1[8] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstNotEqual jjtn002 = new AstNotEqual(JJTNOTEQUAL); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + Compare(); + } catch (Throwable jjte002) { + if (jjtc002) { + jjtree.clearNodeScope(jjtn002); + jjtc002 = false; + } else { + jjtree.popNode(); + } + if (jjte002 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte002; + } + } + if (jjte002 instanceof ParseException) { + { + if (true) throw (ParseException) jjte002; + } + } + { + if (true) throw (Error) jjte002; + } + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, 2); + } + } + break; + default: + jj_la1[9] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + } + + /* + * Compare + * For a bunch of them, then Math + */ + final public void Compare() throws ParseException { + Math(); + label_6: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case GT0: + case GT1: + case LT0: + case LT1: + case GE0: + case GE1: + case LE0: + case LE1: + ; + break; + default: + jj_la1[10] = jj_gen; + break label_6; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case LT0: + case LT1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case LT0: + jj_consume_token(LT0); + break; + case LT1: + jj_consume_token(LT1); + break; + default: + jj_la1[11] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstLessThan jjtn001 = new AstLessThan(JJTLESSTHAN); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Math(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + break; + case GT0: + case GT1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case GT0: + jj_consume_token(GT0); + break; + case GT1: + jj_consume_token(GT1); + break; + default: + jj_la1[12] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstGreaterThan jjtn002 = new AstGreaterThan(JJTGREATERTHAN); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + Math(); + } catch (Throwable jjte002) { + if (jjtc002) { + jjtree.clearNodeScope(jjtn002); + jjtc002 = false; + } else { + jjtree.popNode(); + } + if (jjte002 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte002; + } + } + if (jjte002 instanceof ParseException) { + { + if (true) throw (ParseException) jjte002; + } + } + { + if (true) throw (Error) jjte002; + } + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, 2); + } + } + break; + case LE0: + case LE1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case LE0: + jj_consume_token(LE0); + break; + case LE1: + jj_consume_token(LE1); + break; + default: + jj_la1[13] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstLessThanEqual jjtn003 = new AstLessThanEqual(JJTLESSTHANEQUAL); + boolean jjtc003 = true; + jjtree.openNodeScope(jjtn003); + try { + Math(); + } catch (Throwable jjte003) { + if (jjtc003) { + jjtree.clearNodeScope(jjtn003); + jjtc003 = false; + } else { + jjtree.popNode(); + } + if (jjte003 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte003; + } + } + if (jjte003 instanceof ParseException) { + { + if (true) throw (ParseException) jjte003; + } + } + { + if (true) throw (Error) jjte003; + } + } finally { + if (jjtc003) { + jjtree.closeNodeScope(jjtn003, 2); + } + } + break; + case GE0: + case GE1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case GE0: + jj_consume_token(GE0); + break; + case GE1: + jj_consume_token(GE1); + break; + default: + jj_la1[14] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstGreaterThanEqual jjtn004 = new AstGreaterThanEqual(JJTGREATERTHANEQUAL); + boolean jjtc004 = true; + jjtree.openNodeScope(jjtn004); + try { + Math(); + } catch (Throwable jjte004) { + if (jjtc004) { + jjtree.clearNodeScope(jjtn004); + jjtc004 = false; + } else { + jjtree.popNode(); + } + if (jjte004 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte004; + } + } + if (jjte004 instanceof ParseException) { + { + if (true) throw (ParseException) jjte004; + } + } + { + if (true) throw (Error) jjte004; + } + } finally { + if (jjtc004) { + jjtree.closeNodeScope(jjtn004, 2); + } + } + break; + default: + jj_la1[15] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + } + + /* + * Math + * For '+' '-', then Multiplication + */ + final public void Math() throws ParseException { + Multiplication(); + label_7: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case PLUS: + case MINUS: + ; + break; + default: + jj_la1[16] = jj_gen; + break label_7; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case PLUS: + jj_consume_token(PLUS); + AstPlus jjtn001 = new AstPlus(JJTPLUS); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Multiplication(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + break; + case MINUS: + jj_consume_token(MINUS); + AstMinus jjtn002 = new AstMinus(JJTMINUS); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + Multiplication(); + } catch (Throwable jjte002) { + if (jjtc002) { + jjtree.clearNodeScope(jjtn002); + jjtc002 = false; + } else { + jjtree.popNode(); + } + if (jjte002 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte002; + } + } + if (jjte002 instanceof ParseException) { + { + if (true) throw (ParseException) jjte002; + } + } + { + if (true) throw (Error) jjte002; + } + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, 2); + } + } + break; + default: + jj_la1[17] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + } + + /* + * Multiplication + * For a bunch of them, then Unary + */ + final public void Multiplication() throws ParseException { + Unary(); + label_8: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case MULT: + case DIV0: + case DIV1: + case MOD0: + case MOD1: + ; + break; + default: + jj_la1[18] = jj_gen; + break label_8; + } + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case MULT: + jj_consume_token(MULT); + AstMult jjtn001 = new AstMult(JJTMULT); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Unary(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, 2); + } + } + break; + case DIV0: + case DIV1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case DIV0: + jj_consume_token(DIV0); + break; + case DIV1: + jj_consume_token(DIV1); + break; + default: + jj_la1[19] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstDiv jjtn002 = new AstDiv(JJTDIV); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + Unary(); + } catch (Throwable jjte002) { + if (jjtc002) { + jjtree.clearNodeScope(jjtn002); + jjtc002 = false; + } else { + jjtree.popNode(); + } + if (jjte002 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte002; + } + } + if (jjte002 instanceof ParseException) { + { + if (true) throw (ParseException) jjte002; + } + } + { + if (true) throw (Error) jjte002; + } + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, 2); + } + } + break; + case MOD0: + case MOD1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case MOD0: + jj_consume_token(MOD0); + break; + case MOD1: + jj_consume_token(MOD1); + break; + default: + jj_la1[20] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstMod jjtn003 = new AstMod(JJTMOD); + boolean jjtc003 = true; + jjtree.openNodeScope(jjtn003); + try { + Unary(); + } catch (Throwable jjte003) { + if (jjtc003) { + jjtree.clearNodeScope(jjtn003); + jjtc003 = false; + } else { + jjtree.popNode(); + } + if (jjte003 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte003; + } + } + if (jjte003 instanceof ParseException) { + { + if (true) throw (ParseException) jjte003; + } + } + { + if (true) throw (Error) jjte003; + } + } finally { + if (jjtc003) { + jjtree.closeNodeScope(jjtn003, 2); + } + } + break; + default: + jj_la1[21] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + } + + /* + * Unary + * For '-' '!' 'not' 'empty', then Value + */ + final public void Unary() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case MINUS: + jj_consume_token(MINUS); + AstNegative jjtn001 = new AstNegative(JJTNEGATIVE); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + Unary(); + } catch (Throwable jjte001) { + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, true); + } + } + break; + case NOT0: + case NOT1: + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case NOT0: + jj_consume_token(NOT0); + break; + case NOT1: + jj_consume_token(NOT1); + break; + default: + jj_la1[22] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + AstNot jjtn002 = new AstNot(JJTNOT); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + Unary(); + } catch (Throwable jjte002) { + if (jjtc002) { + jjtree.clearNodeScope(jjtn002); + jjtc002 = false; + } else { + jjtree.popNode(); + } + if (jjte002 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte002; + } + } + if (jjte002 instanceof ParseException) { + { + if (true) throw (ParseException) jjte002; + } + } + { + if (true) throw (Error) jjte002; + } + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, true); + } + } + break; + case EMPTY: + jj_consume_token(EMPTY); + AstEmpty jjtn003 = new AstEmpty(JJTEMPTY); + boolean jjtc003 = true; + jjtree.openNodeScope(jjtn003); + try { + Unary(); + } catch (Throwable jjte003) { + if (jjtc003) { + jjtree.clearNodeScope(jjtn003); + jjtc003 = false; + } else { + jjtree.popNode(); + } + if (jjte003 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte003; + } + } + if (jjte003 instanceof ParseException) { + { + if (true) throw (ParseException) jjte003; + } + } + { + if (true) throw (Error) jjte003; + } + } finally { + if (jjtc003) { + jjtree.closeNodeScope(jjtn003, true); + } + } + break; + case INTEGER_LITERAL: + case FLOATING_POINT_LITERAL: + case STRING_LITERAL: + case TRUE: + case FALSE: + case NULL: + case LPAREN: + case IDENTIFIER: + Value(); + break; + default: + jj_la1[23] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + + /* + * Value + * Defines Prefix plus zero or more Suffixes + */ + final public void Value() throws ParseException { + AstValue jjtn001 = new AstValue(JJTVALUE); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); try { - Compare(); + ValuePrefix(); + label_9: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case DOT: + case LBRACK: + ; + break; + default: + jj_la1[24] = jj_gen; + break label_9; + } + ValueSuffix(); + } } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} + if (jjtc001) { + jjtree.clearNodeScope(jjtn001); + jjtc001 = false; + } else { + jjtree.popNode(); + } + if (jjte001 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte001; + } + } + if (jjte001 instanceof ParseException) { + { + if (true) throw (ParseException) jjte001; + } + } + { + if (true) throw (Error) jjte001; + } } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - break; - case NE0: - case NE1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case NE0: - jj_consume_token(NE0); - break; - case NE1: - jj_consume_token(NE1); - break; - default: - jj_la1[8] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstNotEqual jjtn002 = new AstNotEqual(JJTNOTEQUAL); - boolean jjtc002 = true; - jjtree.openNodeScope(jjtn002); + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, jjtree.nodeArity() > 1); + } + } + } + + /* + * ValuePrefix + * For Literals, Variables, and Functions + */ + final public void ValuePrefix() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case INTEGER_LITERAL: + case FLOATING_POINT_LITERAL: + case STRING_LITERAL: + case TRUE: + case FALSE: + case NULL: + Literal(); + break; + case LPAREN: + case IDENTIFIER: + NonLiteral(); + break; + default: + jj_la1[25] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + + /* + * ValueSuffix + * Either dot or bracket notation + */ + final public void ValueSuffix() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case DOT: + DotSuffix(); + break; + case LBRACK: + BracketSuffix(); + break; + default: + jj_la1[26] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + + /* + * DotSuffix + * Dot Property + */ + final public void DotSuffix() throws ParseException { + /*@bgen(jjtree) DotSuffix */ + AstDotSuffix jjtn000 = new AstDotSuffix(JJTDOTSUFFIX); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; try { - Compare(); - } catch (Throwable jjte002) { - if (jjtc002) { - jjtree.clearNodeScope(jjtn002); - jjtc002 = false; - } else { - jjtree.popNode(); - } - if (jjte002 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte002;} - } - if (jjte002 instanceof ParseException) { - {if (true) throw (ParseException)jjte002;} - } - {if (true) throw (Error)jjte002;} + jj_consume_token(DOT); + t = jj_consume_token(IDENTIFIER); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); } finally { - if (jjtc002) { - jjtree.closeNodeScope(jjtn002, 2); - } - } - break; - default: - jj_la1[9] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - } - -/* - * Compare - * For a bunch of them, then Math - */ - final public void Compare() throws ParseException { - Math(); - label_6: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case GT0: - case GT1: - case LT0: - case LT1: - case GE0: - case GE1: - case LE0: - case LE1: - ; - break; - default: - jj_la1[10] = jj_gen; - break label_6; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case LT0: - case LT1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case LT0: - jj_consume_token(LT0); - break; - case LT1: - jj_consume_token(LT1); - break; - default: - jj_la1[11] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstLessThan jjtn001 = new AstLessThan(JJTLESSTHAN); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * BracketSuffix + * Sub Expression Suffix + */ + final public void BracketSuffix() throws ParseException { + /*@bgen(jjtree) BracketSuffix */ + AstBracketSuffix jjtn000 = new AstBracketSuffix(JJTBRACKETSUFFIX); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); try { - Math(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} + jj_consume_token(LBRACK); + Expression(); + jj_consume_token(RBRACK); + } catch (Throwable jjte000) { + if (jjtc000) { + jjtree.clearNodeScope(jjtn000); + jjtc000 = false; + } else { + jjtree.popNode(); + } + if (jjte000 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte000; + } + } + if (jjte000 instanceof ParseException) { + { + if (true) throw (ParseException) jjte000; + } + } + { + if (true) throw (Error) jjte000; + } } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - break; - case GT0: - case GT1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case GT0: - jj_consume_token(GT0); - break; - case GT1: - jj_consume_token(GT1); - break; - default: - jj_la1[12] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstGreaterThan jjtn002 = new AstGreaterThan(JJTGREATERTHAN); - boolean jjtc002 = true; - jjtree.openNodeScope(jjtn002); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * NonLiteral + * For Grouped Operations, Identifiers, and Functions + */ + final public void NonLiteral() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case LPAREN: + jj_consume_token(LPAREN); + Expression(); + jj_consume_token(RPAREN); + break; + default: + jj_la1[27] = jj_gen; + if (jj_2_2(2147483647)) { + Function(); + } else { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case IDENTIFIER: + Identifier(); + break; + default: + jj_la1[28] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + } + } + + /* + * Identifier + * Java Language Identifier + */ + final public void Identifier() throws ParseException { + /*@bgen(jjtree) Identifier */ + AstIdentifier jjtn000 = new AstIdentifier(JJTIDENTIFIER); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; try { - Math(); - } catch (Throwable jjte002) { - if (jjtc002) { - jjtree.clearNodeScope(jjtn002); - jjtc002 = false; - } else { - jjtree.popNode(); - } - if (jjte002 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte002;} - } - if (jjte002 instanceof ParseException) { - {if (true) throw (ParseException)jjte002;} - } - {if (true) throw (Error)jjte002;} + t = jj_consume_token(IDENTIFIER); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); } finally { - if (jjtc002) { - jjtree.closeNodeScope(jjtn002, 2); - } - } - break; - case LE0: - case LE1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case LE0: - jj_consume_token(LE0); - break; - case LE1: - jj_consume_token(LE1); - break; - default: - jj_la1[13] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstLessThanEqual jjtn003 = new AstLessThanEqual(JJTLESSTHANEQUAL); - boolean jjtc003 = true; - jjtree.openNodeScope(jjtn003); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * Function + * Namespace:Name(a,b,c) + */ + final public void Function() throws ParseException { + /*@bgen(jjtree) Function */ + AstFunction jjtn000 = new AstFunction(JJTFUNCTION); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t0 = null; + Token t1 = null; try { - Math(); - } catch (Throwable jjte003) { - if (jjtc003) { - jjtree.clearNodeScope(jjtn003); - jjtc003 = false; - } else { - jjtree.popNode(); - } - if (jjte003 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte003;} - } - if (jjte003 instanceof ParseException) { - {if (true) throw (ParseException)jjte003;} - } - {if (true) throw (Error)jjte003;} + if (jj_2_3(2)) { + t0 = jj_consume_token(IDENTIFIER); + jj_consume_token(COLON); + } else { + ; + } + t1 = jj_consume_token(IDENTIFIER); + if (t0 != null) { + jjtn000.setPrefix(t0.image); + jjtn000.setLocalName(t1.image); + } else { + jjtn000.setLocalName(t1.image); + } + jj_consume_token(LPAREN); + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case INTEGER_LITERAL: + case FLOATING_POINT_LITERAL: + case STRING_LITERAL: + case TRUE: + case FALSE: + case NULL: + case LPAREN: + case NOT0: + case NOT1: + case EMPTY: + case MINUS: + case IDENTIFIER: + Expression(); + label_10: + while (true) { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case COMMA: + ; + break; + default: + jj_la1[29] = jj_gen; + break label_10; + } + jj_consume_token(COMMA); + Expression(); + } + break; + default: + jj_la1[30] = jj_gen; + ; + } + jj_consume_token(RPAREN); + } catch (Throwable jjte000) { + if (jjtc000) { + jjtree.clearNodeScope(jjtn000); + jjtc000 = false; + } else { + jjtree.popNode(); + } + if (jjte000 instanceof RuntimeException) { + { + if (true) throw (RuntimeException) jjte000; + } + } + if (jjte000 instanceof ParseException) { + { + if (true) throw (ParseException) jjte000; + } + } + { + if (true) throw (Error) jjte000; + } } finally { - if (jjtc003) { - jjtree.closeNodeScope(jjtn003, 2); - } - } - break; - case GE0: - case GE1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case GE0: - jj_consume_token(GE0); - break; - case GE1: - jj_consume_token(GE1); - break; - default: - jj_la1[14] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstGreaterThanEqual jjtn004 = new AstGreaterThanEqual(JJTGREATERTHANEQUAL); - boolean jjtc004 = true; - jjtree.openNodeScope(jjtn004); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * Literal + * Reserved Keywords + */ + final public void Literal() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case TRUE: + case FALSE: + Boolean(); + break; + case FLOATING_POINT_LITERAL: + FloatingPoint(); + break; + case INTEGER_LITERAL: + Integer(); + break; + case STRING_LITERAL: + String(); + break; + case NULL: + Null(); + break; + default: + jj_la1[31] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + + /* + * Boolean + * For 'true' 'false' + */ + final public void Boolean() throws ParseException { + switch ((jj_ntk == -1) ? jj_ntk() : jj_ntk) { + case TRUE: + AstTrue jjtn001 = new AstTrue(JJTTRUE); + boolean jjtc001 = true; + jjtree.openNodeScope(jjtn001); + try { + jj_consume_token(TRUE); + } finally { + if (jjtc001) { + jjtree.closeNodeScope(jjtn001, true); + } + } + break; + case FALSE: + AstFalse jjtn002 = new AstFalse(JJTFALSE); + boolean jjtc002 = true; + jjtree.openNodeScope(jjtn002); + try { + jj_consume_token(FALSE); + } finally { + if (jjtc002) { + jjtree.closeNodeScope(jjtn002, true); + } + } + break; + default: + jj_la1[32] = jj_gen; + jj_consume_token(-1); + throw new ParseException(); + } + } + + /* + * FloatinPoint + * For Decimal and Floating Point Literals + */ + final public void FloatingPoint() throws ParseException { + /*@bgen(jjtree) FloatingPoint */ + AstFloatingPoint jjtn000 = new AstFloatingPoint(JJTFLOATINGPOINT); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; try { - Math(); - } catch (Throwable jjte004) { - if (jjtc004) { - jjtree.clearNodeScope(jjtn004); - jjtc004 = false; - } else { - jjtree.popNode(); - } - if (jjte004 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte004;} - } - if (jjte004 instanceof ParseException) { - {if (true) throw (ParseException)jjte004;} - } - {if (true) throw (Error)jjte004;} + t = jj_consume_token(FLOATING_POINT_LITERAL); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); } finally { - if (jjtc004) { - jjtree.closeNodeScope(jjtn004, 2); - } - } - break; - default: - jj_la1[15] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - } - -/* - * Math - * For '+' '-', then Multiplication - */ - final public void Math() throws ParseException { - Multiplication(); - label_7: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case PLUS: - case MINUS: - ; - break; - default: - jj_la1[16] = jj_gen; - break label_7; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case PLUS: - jj_consume_token(PLUS); - AstPlus jjtn001 = new AstPlus(JJTPLUS); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * Integer + * For Simple Numeric Literals + */ + final public void Integer() throws ParseException { + /*@bgen(jjtree) Integer */ + AstInteger jjtn000 = new AstInteger(JJTINTEGER); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; try { - Multiplication(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} + t = jj_consume_token(INTEGER_LITERAL); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - break; - case MINUS: - jj_consume_token(MINUS); - AstMinus jjtn002 = new AstMinus(JJTMINUS); - boolean jjtc002 = true; - jjtree.openNodeScope(jjtn002); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * String + * For Quoted Literals + */ + final public void String() throws ParseException { + /*@bgen(jjtree) String */ + AstString jjtn000 = new AstString(JJTSTRING); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); + Token t = null; try { - Multiplication(); - } catch (Throwable jjte002) { - if (jjtc002) { - jjtree.clearNodeScope(jjtn002); - jjtc002 = false; - } else { - jjtree.popNode(); - } - if (jjte002 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte002;} - } - if (jjte002 instanceof ParseException) { - {if (true) throw (ParseException)jjte002;} - } - {if (true) throw (Error)jjte002;} + t = jj_consume_token(STRING_LITERAL); + jjtree.closeNodeScope(jjtn000, true); + jjtc000 = false; + jjtn000.setImage(t.image); } finally { - if (jjtc002) { - jjtree.closeNodeScope(jjtn002, 2); - } - } - break; - default: - jj_la1[17] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - } - -/* - * Multiplication - * For a bunch of them, then Unary - */ - final public void Multiplication() throws ParseException { - Unary(); - label_8: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case MULT: - case DIV0: - case DIV1: - case MOD0: - case MOD1: - ; - break; - default: - jj_la1[18] = jj_gen; - break label_8; - } - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case MULT: - jj_consume_token(MULT); - AstMult jjtn001 = new AstMult(JJTMULT); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + /* + * Null + * For 'null' + */ + final public void Null() throws ParseException { + /*@bgen(jjtree) Null */ + AstNull jjtn000 = new AstNull(JJTNULL); + boolean jjtc000 = true; + jjtree.openNodeScope(jjtn000); try { - Unary(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} + jj_consume_token(NULL); } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, 2); - } - } - break; - case DIV0: - case DIV1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case DIV0: - jj_consume_token(DIV0); - break; - case DIV1: - jj_consume_token(DIV1); - break; - default: - jj_la1[19] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstDiv jjtn002 = new AstDiv(JJTDIV); - boolean jjtc002 = true; - jjtree.openNodeScope(jjtn002); + if (jjtc000) { + jjtree.closeNodeScope(jjtn000, true); + } + } + } + + private boolean jj_2_1(int xla) { + jj_la = xla; + jj_lastpos = jj_scanpos = token; try { - Unary(); - } catch (Throwable jjte002) { - if (jjtc002) { - jjtree.clearNodeScope(jjtn002); - jjtc002 = false; - } else { - jjtree.popNode(); - } - if (jjte002 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte002;} - } - if (jjte002 instanceof ParseException) { - {if (true) throw (ParseException)jjte002;} - } - {if (true) throw (Error)jjte002;} + return !jj_3_1(); + } catch (LookaheadSuccess ls) { + return true; } finally { - if (jjtc002) { - jjtree.closeNodeScope(jjtn002, 2); - } - } - break; - case MOD0: - case MOD1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case MOD0: - jj_consume_token(MOD0); - break; - case MOD1: - jj_consume_token(MOD1); - break; - default: - jj_la1[20] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstMod jjtn003 = new AstMod(JJTMOD); - boolean jjtc003 = true; - jjtree.openNodeScope(jjtn003); + jj_save(0, xla); + } + } + + private boolean jj_2_2(int xla) { + jj_la = xla; + jj_lastpos = jj_scanpos = token; try { - Unary(); - } catch (Throwable jjte003) { - if (jjtc003) { - jjtree.clearNodeScope(jjtn003); - jjtc003 = false; - } else { - jjtree.popNode(); - } - if (jjte003 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte003;} - } - if (jjte003 instanceof ParseException) { - {if (true) throw (ParseException)jjte003;} - } - {if (true) throw (Error)jjte003;} + return !jj_3_2(); + } catch (LookaheadSuccess ls) { + return true; } finally { - if (jjtc003) { - jjtree.closeNodeScope(jjtn003, 2); - } - } - break; - default: - jj_la1[21] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - } - -/* - * Unary - * For '-' '!' 'not' 'empty', then Value - */ - final public void Unary() throws ParseException { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case MINUS: - jj_consume_token(MINUS); - AstNegative jjtn001 = new AstNegative(JJTNEGATIVE); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); - try { - Unary(); - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} - } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, true); - } - } - break; - case NOT0: - case NOT1: - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case NOT0: - jj_consume_token(NOT0); - break; - case NOT1: - jj_consume_token(NOT1); - break; - default: - jj_la1[22] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - AstNot jjtn002 = new AstNot(JJTNOT); - boolean jjtc002 = true; - jjtree.openNodeScope(jjtn002); - try { - Unary(); - } catch (Throwable jjte002) { - if (jjtc002) { - jjtree.clearNodeScope(jjtn002); - jjtc002 = false; - } else { - jjtree.popNode(); - } - if (jjte002 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte002;} - } - if (jjte002 instanceof ParseException) { - {if (true) throw (ParseException)jjte002;} - } - {if (true) throw (Error)jjte002;} - } finally { - if (jjtc002) { - jjtree.closeNodeScope(jjtn002, true); - } - } - break; - case EMPTY: - jj_consume_token(EMPTY); - AstEmpty jjtn003 = new AstEmpty(JJTEMPTY); - boolean jjtc003 = true; - jjtree.openNodeScope(jjtn003); - try { - Unary(); - } catch (Throwable jjte003) { - if (jjtc003) { - jjtree.clearNodeScope(jjtn003); - jjtc003 = false; - } else { - jjtree.popNode(); - } - if (jjte003 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte003;} - } - if (jjte003 instanceof ParseException) { - {if (true) throw (ParseException)jjte003;} - } - {if (true) throw (Error)jjte003;} - } finally { - if (jjtc003) { - jjtree.closeNodeScope(jjtn003, true); - } - } - break; - case INTEGER_LITERAL: - case FLOATING_POINT_LITERAL: - case STRING_LITERAL: - case TRUE: - case FALSE: - case NULL: - case LPAREN: - case IDENTIFIER: - Value(); - break; - default: - jj_la1[23] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - -/* - * Value - * Defines Prefix plus zero or more Suffixes - */ - final public void Value() throws ParseException { - AstValue jjtn001 = new AstValue(JJTVALUE); - boolean jjtc001 = true; - jjtree.openNodeScope(jjtn001); - try { - ValuePrefix(); - label_9: - while (true) { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case DOT: - case LBRACK: - ; - break; - default: - jj_la1[24] = jj_gen; - break label_9; - } - ValueSuffix(); - } - } catch (Throwable jjte001) { - if (jjtc001) { - jjtree.clearNodeScope(jjtn001); - jjtc001 = false; - } else { - jjtree.popNode(); - } - if (jjte001 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte001;} - } - if (jjte001 instanceof ParseException) { - {if (true) throw (ParseException)jjte001;} - } - {if (true) throw (Error)jjte001;} - } finally { - if (jjtc001) { - jjtree.closeNodeScope(jjtn001, jjtree.nodeArity() > 1); - } - } - } - -/* - * ValuePrefix - * For Literals, Variables, and Functions - */ - final public void ValuePrefix() throws ParseException { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case INTEGER_LITERAL: - case FLOATING_POINT_LITERAL: - case STRING_LITERAL: - case TRUE: - case FALSE: - case NULL: - Literal(); - break; - case LPAREN: - case IDENTIFIER: - NonLiteral(); - break; - default: - jj_la1[25] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - -/* - * ValueSuffix - * Either dot or bracket notation - */ - final public void ValueSuffix() throws ParseException { - switch ((jj_ntk==-1)?jj_ntk():jj_ntk) { - case DOT: - DotSuffix(); - break; - case LBRACK: - BracketSuffix(); - break; - default: - jj_la1[26] = jj_gen; - jj_consume_token(-1); - throw new ParseException(); - } - } - -/* - * DotSuffix - * Dot Property - */ - final public void DotSuffix() throws ParseException { - /*@bgen(jjtree) DotSuffix */ - AstDotSuffix jjtn000 = new AstDotSuffix(JJTDOTSUFFIX); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000);Token t = null; - try { - jj_consume_token(DOT); - t = jj_consume_token(IDENTIFIER); - jjtree.closeNodeScope(jjtn000, true); - jjtc000 = false; - jjtn000.setImage(t.image); - } finally { - if (jjtc000) { - jjtree.closeNodeScope(jjtn000, true); - } - } - } - -/* - * BracketSuffix - * Sub Expression Suffix - */ - final public void BracketSuffix() throws ParseException { - /*@bgen(jjtree) BracketSuffix */ - AstBracketSuffix jjtn000 = new AstBracketSuffix(JJTBRACKETSUFFIX); - boolean jjtc000 = true; - jjtree.openNodeScope(jjtn000); - try { - jj_consume_token(LBRACK); - Expression(); - jj_consume_token(RBRACK); - } catch (Throwable jjte000) { - if (jjtc000) { - jjtree.clearNodeScope(jjtn000); - jjtc000 = false; - } else { - jjtree.popNode(); - } - if (jjte000 instanceof RuntimeException) { - {if (true) throw (RuntimeException)jjte000;} - }
<TRUNCATED>