
org.intermine.sql.query.SqlTreeParser Maven / Gradle / Ivy
// $ANTLR : "intermine_sql.g" -> "SqlTreeParser.java"$
package org.intermine.sql.query;
import antlr.TreeParser;
import antlr.Token;
import antlr.collections.AST;
import antlr.RecognitionException;
import antlr.ANTLRException;
import antlr.NoViableAltException;
import antlr.MismatchedTokenException;
import antlr.SemanticException;
import antlr.collections.impl.BitSet;
import antlr.ASTPair;
import antlr.collections.impl.ASTArray;
public class SqlTreeParser extends antlr.TreeParser implements SqlTokenTypes
{
public SqlTreeParser() {
tokenNames = _tokenNames;
}
public final void start_rule(AST _t) throws RecognitionException {
AST start_rule_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST start_rule_AST = null;
sql(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
start_rule_AST = (AST)currentAST.root;
returnAST = start_rule_AST;
_retTree = _t;
}
public final void sql(AST _t) throws RecognitionException {
AST sql_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST sql_AST = null;
sql_statement(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
_loop243:
do {
if (_t==null) _t=ASTNULL;
if ((_t.getType()==SQL_STATEMENT)) {
sql_statement(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
break _loop243;
}
} while (true);
}
sql_AST = (AST)currentAST.root;
returnAST = sql_AST;
_retTree = _t;
}
public final void sql_statement(AST _t) throws RecognitionException {
AST sql_statement_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST sql_statement_AST = null;
AST __t245 = _t;
AST tmp1_AST = null;
AST tmp1_AST_in = null;
tmp1_AST = astFactory.create((AST)_t);
tmp1_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp1_AST);
ASTPair __currentAST245 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SQL_STATEMENT);
_t = _t.getFirstChild();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_explain:
{
AST tmp2_AST = null;
AST tmp2_AST_in = null;
tmp2_AST = astFactory.create((AST)_t);
tmp2_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp2_AST);
match(_t,LITERAL_explain);
_t = _t.getNextSibling();
break;
}
case SELECT_LIST:
case LITERAL_distinct:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_distinct:
{
AST tmp3_AST = null;
AST tmp3_AST_in = null;
tmp3_AST = astFactory.create((AST)_t);
tmp3_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp3_AST);
match(_t,LITERAL_distinct);
_t = _t.getNextSibling();
break;
}
case SELECT_LIST:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
select_list(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case FROM_LIST:
{
from_list(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case WHERE_CLAUSE:
{
where_clause(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
case GROUP_CLAUSE:
case ORDER_CLAUSE:
case LIMIT_CLAUSE:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case GROUP_CLAUSE:
{
group_clause(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case HAVING_CLAUSE:
{
having_clause(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
case ORDER_CLAUSE:
case LIMIT_CLAUSE:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
break;
}
case 3:
case ORDER_CLAUSE:
case LIMIT_CLAUSE:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case ORDER_CLAUSE:
{
order_clause(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
case LIMIT_CLAUSE:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LIMIT_CLAUSE:
{
limit_clause(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST245;
_t = __t245;
_t = _t.getNextSibling();
sql_statement_AST = (AST)currentAST.root;
returnAST = sql_statement_AST;
_retTree = _t;
}
public final void select_list(AST _t) throws RecognitionException {
AST select_list_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST select_list_AST = null;
AST __t255 = _t;
AST tmp4_AST = null;
AST tmp4_AST_in = null;
tmp4_AST = astFactory.create((AST)_t);
tmp4_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp4_AST);
ASTPair __currentAST255 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SELECT_LIST);
_t = _t.getFirstChild();
{
int _cnt257=0;
_loop257:
do {
if (_t==null) _t=ASTNULL;
if ((_t.getType()==SELECT_VALUE)) {
select_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt257>=1 ) { break _loop257; } else {throw new NoViableAltException(_t);}
}
_cnt257++;
} while (true);
}
currentAST = __currentAST255;
_t = __t255;
_t = _t.getNextSibling();
select_list_AST = (AST)currentAST.root;
returnAST = select_list_AST;
_retTree = _t;
}
public final void from_list(AST _t) throws RecognitionException {
AST from_list_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST from_list_AST = null;
AST __t259 = _t;
AST tmp5_AST = null;
AST tmp5_AST_in = null;
tmp5_AST = astFactory.create((AST)_t);
tmp5_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp5_AST);
ASTPair __currentAST259 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,FROM_LIST);
_t = _t.getFirstChild();
{
int _cnt261=0;
_loop261:
do {
if (_t==null) _t=ASTNULL;
if ((_t.getType()==TABLE||_t.getType()==SUBQUERY)) {
abstract_table(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt261>=1 ) { break _loop261; } else {throw new NoViableAltException(_t);}
}
_cnt261++;
} while (true);
}
currentAST = __currentAST259;
_t = __t259;
_t = _t.getNextSibling();
from_list_AST = (AST)currentAST.root;
returnAST = from_list_AST;
_retTree = _t;
}
public final void where_clause(AST _t) throws RecognitionException {
AST where_clause_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST where_clause_AST = null;
AST __t263 = _t;
AST tmp6_AST = null;
AST tmp6_AST_in = null;
tmp6_AST = astFactory.create((AST)_t);
tmp6_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp6_AST);
ASTPair __currentAST263 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,WHERE_CLAUSE);
_t = _t.getFirstChild();
{
int _cnt265=0;
_loop265:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt265>=1 ) { break _loop265; } else {throw new NoViableAltException(_t);}
}
_cnt265++;
} while (true);
}
currentAST = __currentAST263;
_t = __t263;
_t = _t.getNextSibling();
where_clause_AST = (AST)currentAST.root;
returnAST = where_clause_AST;
_retTree = _t;
}
public final void group_clause(AST _t) throws RecognitionException {
AST group_clause_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST group_clause_AST = null;
AST __t267 = _t;
AST tmp7_AST = null;
AST tmp7_AST_in = null;
tmp7_AST = astFactory.create((AST)_t);
tmp7_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp7_AST);
ASTPair __currentAST267 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,GROUP_CLAUSE);
_t = _t.getFirstChild();
{
int _cnt269=0;
_loop269:
do {
if (_t==null) _t=ASTNULL;
if ((_tokenSet_0.member(_t.getType()))) {
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt269>=1 ) { break _loop269; } else {throw new NoViableAltException(_t);}
}
_cnt269++;
} while (true);
}
currentAST = __currentAST267;
_t = __t267;
_t = _t.getNextSibling();
group_clause_AST = (AST)currentAST.root;
returnAST = group_clause_AST;
_retTree = _t;
}
public final void having_clause(AST _t) throws RecognitionException {
AST having_clause_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST having_clause_AST = null;
AST __t271 = _t;
AST tmp8_AST = null;
AST tmp8_AST_in = null;
tmp8_AST = astFactory.create((AST)_t);
tmp8_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp8_AST);
ASTPair __currentAST271 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,HAVING_CLAUSE);
_t = _t.getFirstChild();
{
int _cnt273=0;
_loop273:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt273>=1 ) { break _loop273; } else {throw new NoViableAltException(_t);}
}
_cnt273++;
} while (true);
}
currentAST = __currentAST271;
_t = __t271;
_t = _t.getNextSibling();
having_clause_AST = (AST)currentAST.root;
returnAST = having_clause_AST;
_retTree = _t;
}
public final void order_clause(AST _t) throws RecognitionException {
AST order_clause_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST order_clause_AST = null;
AST __t275 = _t;
AST tmp9_AST = null;
AST tmp9_AST_in = null;
tmp9_AST = astFactory.create((AST)_t);
tmp9_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp9_AST);
ASTPair __currentAST275 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,ORDER_CLAUSE);
_t = _t.getFirstChild();
{
int _cnt277=0;
_loop277:
do {
if (_t==null) _t=ASTNULL;
if ((_tokenSet_1.member(_t.getType()))) {
orderby_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt277>=1 ) { break _loop277; } else {throw new NoViableAltException(_t);}
}
_cnt277++;
} while (true);
}
currentAST = __currentAST275;
_t = __t275;
_t = _t.getNextSibling();
order_clause_AST = (AST)currentAST.root;
returnAST = order_clause_AST;
_retTree = _t;
}
public final void limit_clause(AST _t) throws RecognitionException {
AST limit_clause_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST limit_clause_AST = null;
AST __t279 = _t;
AST tmp10_AST = null;
AST tmp10_AST_in = null;
tmp10_AST = astFactory.create((AST)_t);
tmp10_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp10_AST);
ASTPair __currentAST279 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,LIMIT_CLAUSE);
_t = _t.getFirstChild();
AST tmp11_AST = null;
AST tmp11_AST_in = null;
tmp11_AST = astFactory.create((AST)_t);
tmp11_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp11_AST);
match(_t,INTEGER);
_t = _t.getNextSibling();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case INTEGER:
{
AST tmp12_AST = null;
AST tmp12_AST_in = null;
tmp12_AST = astFactory.create((AST)_t);
tmp12_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp12_AST);
match(_t,INTEGER);
_t = _t.getNextSibling();
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST279;
_t = __t279;
_t = _t.getNextSibling();
limit_clause_AST = (AST)currentAST.root;
returnAST = limit_clause_AST;
_retTree = _t;
}
public final void select_value(AST _t) throws RecognitionException {
AST select_value_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST select_value_AST = null;
AST __t282 = _t;
AST tmp13_AST = null;
AST tmp13_AST_in = null;
tmp13_AST = astFactory.create((AST)_t);
tmp13_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp13_AST);
ASTPair __currentAST282 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SELECT_VALUE);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case FIELD_ALIAS:
{
field_alias(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST282;
_t = __t282;
_t = _t.getNextSibling();
select_value_AST = (AST)currentAST.root;
returnAST = select_value_AST;
_retTree = _t;
}
public final void abstract_table(AST _t) throws RecognitionException {
AST abstract_table_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_table_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case TABLE:
{
table(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_table_AST = (AST)currentAST.root;
break;
}
case SUBQUERY:
{
subquery(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_table_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = abstract_table_AST;
_retTree = _t;
}
public final void abstract_constraint(AST _t) throws RecognitionException {
AST abstract_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_constraint_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case NOT_CONSTRAINT:
{
not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case AND_CONSTRAINT_SET:
{
and_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case OR_CONSTRAINT_SET:
{
or_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
case NULL_CONSTRAINT:
{
null_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_constraint_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = abstract_constraint_AST;
_retTree = _t;
}
public final void abstract_value(AST _t) throws RecognitionException {
AST abstract_value_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_value_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case UNSAFE_FUNCTION:
{
unsafe_function(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value_AST = (AST)currentAST.root;
break;
}
case SAFE_FUNCTION:
{
safe_function(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value_AST = (AST)currentAST.root;
break;
}
case TYPECAST:
{
typecast(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value_AST = (AST)currentAST.root;
break;
}
case CONSTANT:
{
constant(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value_AST = (AST)currentAST.root;
break;
}
case FIELD:
{
field(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = abstract_value_AST;
_retTree = _t;
}
public final void orderby_value(AST _t) throws RecognitionException {
AST orderby_value_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST orderby_value_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case ORDER_DESC:
{
AST __t286 = _t;
AST tmp14_AST = null;
AST tmp14_AST_in = null;
tmp14_AST = astFactory.create((AST)_t);
tmp14_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp14_AST);
ASTPair __currentAST286 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,ORDER_DESC);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST286;
_t = __t286;
_t = _t.getNextSibling();
orderby_value_AST = (AST)currentAST.root;
break;
}
case CONSTANT:
case FIELD:
case SAFE_FUNCTION:
case UNSAFE_FUNCTION:
case TYPECAST:
{
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
orderby_value_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = orderby_value_AST;
_retTree = _t;
}
public final void field_alias(AST _t) throws RecognitionException {
AST field_alias_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST field_alias_AST = null;
AST __t289 = _t;
AST tmp15_AST = null;
AST tmp15_AST_in = null;
tmp15_AST = astFactory.create((AST)_t);
tmp15_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp15_AST);
ASTPair __currentAST289 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,FIELD_ALIAS);
_t = _t.getFirstChild();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case ALIAS:
{
AST tmp16_AST = null;
AST tmp16_AST_in = null;
tmp16_AST = astFactory.create((AST)_t);
tmp16_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp16_AST);
match(_t,ALIAS);
_t = _t.getNextSibling();
break;
}
case IDENTIFIER:
{
AST tmp17_AST = null;
AST tmp17_AST_in = null;
tmp17_AST = astFactory.create((AST)_t);
tmp17_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp17_AST);
match(_t,IDENTIFIER);
_t = _t.getNextSibling();
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST289;
_t = __t289;
_t = _t.getNextSibling();
field_alias_AST = (AST)currentAST.root;
returnAST = field_alias_AST;
_retTree = _t;
}
public final void table(AST _t) throws RecognitionException {
AST table_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST table_AST = null;
AST __t292 = _t;
AST tmp18_AST = null;
AST tmp18_AST_in = null;
tmp18_AST = astFactory.create((AST)_t);
tmp18_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp18_AST);
ASTPair __currentAST292 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,TABLE);
_t = _t.getFirstChild();
table_name(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case TABLE_ALIAS:
{
table_alias(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST292;
_t = __t292;
_t = _t.getNextSibling();
table_AST = (AST)currentAST.root;
returnAST = table_AST;
_retTree = _t;
}
public final void subquery(AST _t) throws RecognitionException {
AST subquery_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST subquery_AST = null;
AST __t295 = _t;
AST tmp19_AST = null;
AST tmp19_AST_in = null;
tmp19_AST = astFactory.create((AST)_t);
tmp19_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp19_AST);
ASTPair __currentAST295 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SUBQUERY);
_t = _t.getFirstChild();
sql(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
table_alias(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST295;
_t = __t295;
_t = _t.getNextSibling();
subquery_AST = (AST)currentAST.root;
returnAST = subquery_AST;
_retTree = _t;
}
public final void unsafe_function(AST _t) throws RecognitionException {
AST unsafe_function_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST unsafe_function_AST = null;
AST __t315 = _t;
AST tmp20_AST = null;
AST tmp20_AST_in = null;
tmp20_AST = astFactory.create((AST)_t);
tmp20_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp20_AST);
ASTPair __currentAST315 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,UNSAFE_FUNCTION);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
int _cnt318=0;
_loop318:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= PLUS && _t.getType() <= MINUS))) {
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case PLUS:
{
AST tmp21_AST = null;
AST tmp21_AST_in = null;
tmp21_AST = astFactory.create((AST)_t);
tmp21_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp21_AST);
match(_t,PLUS);
_t = _t.getNextSibling();
break;
}
case PERCENT:
{
AST tmp22_AST = null;
AST tmp22_AST_in = null;
tmp22_AST = astFactory.create((AST)_t);
tmp22_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp22_AST);
match(_t,PERCENT);
_t = _t.getNextSibling();
break;
}
case ASTERISK:
{
AST tmp23_AST = null;
AST tmp23_AST_in = null;
tmp23_AST = astFactory.create((AST)_t);
tmp23_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp23_AST);
match(_t,ASTERISK);
_t = _t.getNextSibling();
break;
}
case DIVIDE:
{
AST tmp24_AST = null;
AST tmp24_AST_in = null;
tmp24_AST = astFactory.create((AST)_t);
tmp24_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp24_AST);
match(_t,DIVIDE);
_t = _t.getNextSibling();
break;
}
case POWER:
{
AST tmp25_AST = null;
AST tmp25_AST_in = null;
tmp25_AST = astFactory.create((AST)_t);
tmp25_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp25_AST);
match(_t,POWER);
_t = _t.getNextSibling();
break;
}
case MINUS:
{
AST tmp26_AST = null;
AST tmp26_AST_in = null;
tmp26_AST = astFactory.create((AST)_t);
tmp26_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp26_AST);
match(_t,MINUS);
_t = _t.getNextSibling();
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt318>=1 ) { break _loop318; } else {throw new NoViableAltException(_t);}
}
_cnt318++;
} while (true);
}
currentAST = __currentAST315;
_t = __t315;
_t = _t.getNextSibling();
unsafe_function_AST = (AST)currentAST.root;
returnAST = unsafe_function_AST;
_retTree = _t;
}
public final void safe_function(AST _t) throws RecognitionException {
AST safe_function_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST safe_function_AST = null;
AST __t311 = _t;
AST tmp27_AST = null;
AST tmp27_AST_in = null;
tmp27_AST = astFactory.create((AST)_t);
tmp27_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp27_AST);
ASTPair __currentAST311 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SAFE_FUNCTION);
_t = _t.getFirstChild();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_count:
{
AST tmp28_AST = null;
AST tmp28_AST_in = null;
tmp28_AST = astFactory.create((AST)_t);
tmp28_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp28_AST);
match(_t,LITERAL_count);
_t = _t.getNextSibling();
break;
}
case LITERAL_max:
{
AST tmp29_AST = null;
AST tmp29_AST_in = null;
tmp29_AST = astFactory.create((AST)_t);
tmp29_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp29_AST);
match(_t,LITERAL_max);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_min:
{
AST tmp30_AST = null;
AST tmp30_AST_in = null;
tmp30_AST = astFactory.create((AST)_t);
tmp30_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp30_AST);
match(_t,LITERAL_min);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_sum:
{
AST tmp31_AST = null;
AST tmp31_AST_in = null;
tmp31_AST = astFactory.create((AST)_t);
tmp31_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp31_AST);
match(_t,LITERAL_sum);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_avg:
{
AST tmp32_AST = null;
AST tmp32_AST_in = null;
tmp32_AST = astFactory.create((AST)_t);
tmp32_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp32_AST);
match(_t,LITERAL_avg);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_lower:
{
AST tmp33_AST = null;
AST tmp33_AST_in = null;
tmp33_AST = astFactory.create((AST)_t);
tmp33_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp33_AST);
match(_t,LITERAL_lower);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_upper:
{
AST tmp34_AST = null;
AST tmp34_AST_in = null;
tmp34_AST = astFactory.create((AST)_t);
tmp34_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp34_AST);
match(_t,LITERAL_upper);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_greatest:
{
AST tmp35_AST = null;
AST tmp35_AST_in = null;
tmp35_AST = astFactory.create((AST)_t);
tmp35_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp35_AST);
match(_t,LITERAL_greatest);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_least:
{
AST tmp36_AST = null;
AST tmp36_AST_in = null;
tmp36_AST = astFactory.create((AST)_t);
tmp36_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp36_AST);
match(_t,LITERAL_least);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_strpos:
{
AST tmp37_AST = null;
AST tmp37_AST_in = null;
tmp37_AST = astFactory.create((AST)_t);
tmp37_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp37_AST);
match(_t,LITERAL_strpos);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_substr:
{
AST tmp38_AST = null;
AST tmp38_AST_in = null;
tmp38_AST = astFactory.create((AST)_t);
tmp38_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp38_AST);
match(_t,LITERAL_substr);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTANT:
case FIELD:
case SAFE_FUNCTION:
case UNSAFE_FUNCTION:
case TYPECAST:
{
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
break;
}
case LITERAL_coalesce:
{
AST tmp39_AST = null;
AST tmp39_AST_in = null;
tmp39_AST = astFactory.create((AST)_t);
tmp39_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp39_AST);
match(_t,LITERAL_coalesce);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case LITERAL_stddev:
{
AST tmp40_AST = null;
AST tmp40_AST_in = null;
tmp40_AST = astFactory.create((AST)_t);
tmp40_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp40_AST);
match(_t,LITERAL_stddev);
_t = _t.getNextSibling();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST311;
_t = __t311;
_t = _t.getNextSibling();
safe_function_AST = (AST)currentAST.root;
returnAST = safe_function_AST;
_retTree = _t;
}
public final void typecast(AST _t) throws RecognitionException {
AST typecast_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST typecast_AST = null;
AST __t304 = _t;
AST tmp41_AST = null;
AST tmp41_AST_in = null;
tmp41_AST = astFactory.create((AST)_t);
tmp41_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp41_AST);
ASTPair __currentAST304 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,TYPECAST);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
int _cnt306=0;
_loop306:
do {
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_boolean:
{
AST tmp42_AST = null;
AST tmp42_AST_in = null;
tmp42_AST = astFactory.create((AST)_t);
tmp42_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp42_AST);
match(_t,LITERAL_boolean);
_t = _t.getNextSibling();
break;
}
case LITERAL_real:
{
AST tmp43_AST = null;
AST tmp43_AST_in = null;
tmp43_AST = astFactory.create((AST)_t);
tmp43_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp43_AST);
match(_t,LITERAL_real);
_t = _t.getNextSibling();
break;
}
case LITERAL_double:
{
AST tmp44_AST = null;
AST tmp44_AST_in = null;
tmp44_AST = astFactory.create((AST)_t);
tmp44_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp44_AST);
match(_t,LITERAL_double);
_t = _t.getNextSibling();
break;
}
case LITERAL_smallint:
{
AST tmp45_AST = null;
AST tmp45_AST_in = null;
tmp45_AST = astFactory.create((AST)_t);
tmp45_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp45_AST);
match(_t,LITERAL_smallint);
_t = _t.getNextSibling();
break;
}
case LITERAL_integer:
{
AST tmp46_AST = null;
AST tmp46_AST_in = null;
tmp46_AST = astFactory.create((AST)_t);
tmp46_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp46_AST);
match(_t,LITERAL_integer);
_t = _t.getNextSibling();
break;
}
case LITERAL_bigint:
{
AST tmp47_AST = null;
AST tmp47_AST_in = null;
tmp47_AST = astFactory.create((AST)_t);
tmp47_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp47_AST);
match(_t,LITERAL_bigint);
_t = _t.getNextSibling();
break;
}
case LITERAL_numeric:
{
AST tmp48_AST = null;
AST tmp48_AST_in = null;
tmp48_AST = astFactory.create((AST)_t);
tmp48_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp48_AST);
match(_t,LITERAL_numeric);
_t = _t.getNextSibling();
break;
}
case LITERAL_text:
{
AST tmp49_AST = null;
AST tmp49_AST_in = null;
tmp49_AST = astFactory.create((AST)_t);
tmp49_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp49_AST);
match(_t,LITERAL_text);
_t = _t.getNextSibling();
break;
}
default:
{
if ( _cnt306>=1 ) { break _loop306; } else {throw new NoViableAltException(_t);}
}
}
_cnt306++;
} while (true);
}
currentAST = __currentAST304;
_t = __t304;
_t = _t.getNextSibling();
typecast_AST = (AST)currentAST.root;
returnAST = typecast_AST;
_retTree = _t;
}
public final void constant(AST _t) throws RecognitionException {
AST constant_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST constant_AST = null;
AST __t301 = _t;
AST tmp50_AST = null;
AST tmp50_AST_in = null;
tmp50_AST = astFactory.create((AST)_t);
tmp50_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp50_AST);
ASTPair __currentAST301 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTANT);
_t = _t.getFirstChild();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case QUOTED_STRING:
{
AST tmp51_AST = null;
AST tmp51_AST_in = null;
tmp51_AST = astFactory.create((AST)_t);
tmp51_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp51_AST);
match(_t,QUOTED_STRING);
_t = _t.getNextSibling();
break;
}
case ESCAPED_STRING:
{
AST tmp52_AST = null;
AST tmp52_AST_in = null;
tmp52_AST = astFactory.create((AST)_t);
tmp52_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp52_AST);
match(_t,ESCAPED_STRING);
_t = _t.getNextSibling();
break;
}
case INTEGER:
{
AST tmp53_AST = null;
AST tmp53_AST_in = null;
tmp53_AST = astFactory.create((AST)_t);
tmp53_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp53_AST);
match(_t,INTEGER);
_t = _t.getNextSibling();
break;
}
case FLOAT:
{
AST tmp54_AST = null;
AST tmp54_AST_in = null;
tmp54_AST = astFactory.create((AST)_t);
tmp54_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp54_AST);
match(_t,FLOAT);
_t = _t.getNextSibling();
break;
}
case LITERAL_true:
{
AST tmp55_AST = null;
AST tmp55_AST_in = null;
tmp55_AST = astFactory.create((AST)_t);
tmp55_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp55_AST);
match(_t,LITERAL_true);
_t = _t.getNextSibling();
break;
}
case LITERAL_false:
{
AST tmp56_AST = null;
AST tmp56_AST_in = null;
tmp56_AST = astFactory.create((AST)_t);
tmp56_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp56_AST);
match(_t,LITERAL_false);
_t = _t.getNextSibling();
break;
}
case LITERAL_null:
{
AST tmp57_AST = null;
AST tmp57_AST_in = null;
tmp57_AST = astFactory.create((AST)_t);
tmp57_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp57_AST);
match(_t,LITERAL_null);
_t = _t.getNextSibling();
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST301;
_t = __t301;
_t = _t.getNextSibling();
constant_AST = (AST)currentAST.root;
returnAST = constant_AST;
_retTree = _t;
}
public final void field(AST _t) throws RecognitionException {
AST field_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST field_AST = null;
AST __t308 = _t;
AST tmp58_AST = null;
AST tmp58_AST_in = null;
tmp58_AST = astFactory.create((AST)_t);
tmp58_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp58_AST);
ASTPair __currentAST308 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,FIELD);
_t = _t.getFirstChild();
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case TABLE_ALIAS:
{
table_alias(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case FIELD_NAME:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
field_name(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST308;
_t = __t308;
_t = _t.getNextSibling();
field_AST = (AST)currentAST.root;
returnAST = field_AST;
_retTree = _t;
}
public final void table_name(AST _t) throws RecognitionException {
AST table_name_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST table_name_AST = null;
AST __t297 = _t;
AST tmp59_AST = null;
AST tmp59_AST_in = null;
tmp59_AST = astFactory.create((AST)_t);
tmp59_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp59_AST);
ASTPair __currentAST297 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,TABLE_NAME);
_t = _t.getFirstChild();
AST tmp60_AST = null;
AST tmp60_AST_in = null;
tmp60_AST = astFactory.create((AST)_t);
tmp60_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp60_AST);
match(_t,IDENTIFIER);
_t = _t.getNextSibling();
currentAST = __currentAST297;
_t = __t297;
_t = _t.getNextSibling();
table_name_AST = (AST)currentAST.root;
returnAST = table_name_AST;
_retTree = _t;
}
public final void table_alias(AST _t) throws RecognitionException {
AST table_alias_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST table_alias_AST = null;
AST __t299 = _t;
AST tmp61_AST = null;
AST tmp61_AST_in = null;
tmp61_AST = astFactory.create((AST)_t);
tmp61_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp61_AST);
ASTPair __currentAST299 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,TABLE_ALIAS);
_t = _t.getFirstChild();
AST tmp62_AST = null;
AST tmp62_AST_in = null;
tmp62_AST = astFactory.create((AST)_t);
tmp62_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp62_AST);
match(_t,IDENTIFIER);
_t = _t.getNextSibling();
currentAST = __currentAST299;
_t = __t299;
_t = _t.getNextSibling();
table_alias_AST = (AST)currentAST.root;
returnAST = table_alias_AST;
_retTree = _t;
}
public final void field_name(AST _t) throws RecognitionException {
AST field_name_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST field_name_AST = null;
AST __t320 = _t;
AST tmp63_AST = null;
AST tmp63_AST_in = null;
tmp63_AST = astFactory.create((AST)_t);
tmp63_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp63_AST);
ASTPair __currentAST320 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,FIELD_NAME);
_t = _t.getFirstChild();
AST tmp64_AST = null;
AST tmp64_AST_in = null;
tmp64_AST = astFactory.create((AST)_t);
tmp64_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp64_AST);
match(_t,IDENTIFIER);
_t = _t.getNextSibling();
currentAST = __currentAST320;
_t = __t320;
_t = _t.getNextSibling();
field_name_AST = (AST)currentAST.root;
returnAST = field_name_AST;
_retTree = _t;
}
public final void constraint(AST _t) throws RecognitionException {
AST constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST constraint_AST = null;
AST aleft_AST = null;
AST aleft = null;
AST aright_AST = null;
AST aright = null;
AST bleft_AST = null;
AST bleft = null;
AST bright_AST = null;
AST bright = null;
AST cleft_AST = null;
AST cleft = null;
AST cright_AST = null;
AST cright = null;
AST dleft_AST = null;
AST dleft = null;
AST dright_AST = null;
AST dright = null;
AST eleft_AST = null;
AST eleft = null;
AST elike = null;
AST elike_AST = null;
AST eright_AST = null;
AST eright = null;
boolean synPredMatched325 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==CONSTRAINT))) {
AST __t325 = _t;
synPredMatched325 = true;
inputState.guessing++;
try {
{
AST __t324 = _t;
ASTPair __currentAST324 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,NOT_EQ);
_t = _t.getNextSibling();
currentAST = __currentAST324;
_t = __t324;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched325 = false;
}
_t = __t325;
inputState.guessing--;
}
if ( synPredMatched325 ) {
AST __t326 = _t;
AST tmp65_AST = null;
AST tmp65_AST_in = null;
tmp65_AST = astFactory.create((AST)_t);
tmp65_AST_in = (AST)_t;
ASTPair __currentAST326 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
aleft = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
aleft_AST = (AST)returnAST;
AST tmp66_AST = null;
AST tmp66_AST_in = null;
tmp66_AST = astFactory.create((AST)_t);
tmp66_AST_in = (AST)_t;
match(_t,NOT_EQ);
_t = _t.getNextSibling();
aright = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
aright_AST = (AST)returnAST;
currentAST = __currentAST326;
_t = __t326;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
constraint_AST = (AST)currentAST.root;
constraint_AST = (AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(NOT_CONSTRAINT,"NOT_CONSTRAINT")).add((AST)astFactory.make( (new ASTArray(4)).add(astFactory.create(tmp65_AST)).add(aleft_AST).add(astFactory.create(EQ,"=")).add(aright_AST))));
currentAST.root = constraint_AST;
currentAST.child = constraint_AST!=null &&constraint_AST.getFirstChild()!=null ?
constraint_AST.getFirstChild() : constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched329 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==CONSTRAINT))) {
AST __t329 = _t;
synPredMatched329 = true;
inputState.guessing++;
try {
{
AST __t328 = _t;
ASTPair __currentAST328 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,GE);
_t = _t.getNextSibling();
currentAST = __currentAST328;
_t = __t328;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched329 = false;
}
_t = __t329;
inputState.guessing--;
}
if ( synPredMatched329 ) {
AST __t330 = _t;
AST tmp67_AST = null;
AST tmp67_AST_in = null;
tmp67_AST = astFactory.create((AST)_t);
tmp67_AST_in = (AST)_t;
ASTPair __currentAST330 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
bleft = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
bleft_AST = (AST)returnAST;
AST tmp68_AST = null;
AST tmp68_AST_in = null;
tmp68_AST = astFactory.create((AST)_t);
tmp68_AST_in = (AST)_t;
match(_t,GE);
_t = _t.getNextSibling();
bright = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
bright_AST = (AST)returnAST;
currentAST = __currentAST330;
_t = __t330;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
constraint_AST = (AST)currentAST.root;
constraint_AST = (AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(NOT_CONSTRAINT,"NOT_CONSTRAINT")).add((AST)astFactory.make( (new ASTArray(4)).add(astFactory.create(tmp67_AST)).add(bleft_AST).add(astFactory.create(LT,"<")).add(bright_AST))));
currentAST.root = constraint_AST;
currentAST.child = constraint_AST!=null &&constraint_AST.getFirstChild()!=null ?
constraint_AST.getFirstChild() : constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched333 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==CONSTRAINT))) {
AST __t333 = _t;
synPredMatched333 = true;
inputState.guessing++;
try {
{
AST __t332 = _t;
ASTPair __currentAST332 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,LE);
_t = _t.getNextSibling();
currentAST = __currentAST332;
_t = __t332;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched333 = false;
}
_t = __t333;
inputState.guessing--;
}
if ( synPredMatched333 ) {
AST __t334 = _t;
AST tmp69_AST = null;
AST tmp69_AST_in = null;
tmp69_AST = astFactory.create((AST)_t);
tmp69_AST_in = (AST)_t;
ASTPair __currentAST334 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
cleft = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
cleft_AST = (AST)returnAST;
AST tmp70_AST = null;
AST tmp70_AST_in = null;
tmp70_AST = astFactory.create((AST)_t);
tmp70_AST_in = (AST)_t;
match(_t,LE);
_t = _t.getNextSibling();
cright = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
cright_AST = (AST)returnAST;
currentAST = __currentAST334;
_t = __t334;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
constraint_AST = (AST)currentAST.root;
constraint_AST = (AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(NOT_CONSTRAINT,"NOT_CONSTRAINT")).add((AST)astFactory.make( (new ASTArray(4)).add(astFactory.create(tmp69_AST)).add(cright_AST).add(astFactory.create(LT,"<")).add(cleft_AST))));
currentAST.root = constraint_AST;
currentAST.child = constraint_AST!=null &&constraint_AST.getFirstChild()!=null ?
constraint_AST.getFirstChild() : constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched337 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==CONSTRAINT))) {
AST __t337 = _t;
synPredMatched337 = true;
inputState.guessing++;
try {
{
AST __t336 = _t;
ASTPair __currentAST336 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,GT);
_t = _t.getNextSibling();
currentAST = __currentAST336;
_t = __t336;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched337 = false;
}
_t = __t337;
inputState.guessing--;
}
if ( synPredMatched337 ) {
AST __t338 = _t;
AST tmp71_AST = null;
AST tmp71_AST_in = null;
tmp71_AST = astFactory.create((AST)_t);
tmp71_AST_in = (AST)_t;
ASTPair __currentAST338 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
dleft = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
dleft_AST = (AST)returnAST;
AST tmp72_AST = null;
AST tmp72_AST_in = null;
tmp72_AST = astFactory.create((AST)_t);
tmp72_AST_in = (AST)_t;
match(_t,GT);
_t = _t.getNextSibling();
dright = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
dright_AST = (AST)returnAST;
currentAST = __currentAST338;
_t = __t338;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
constraint_AST = (AST)currentAST.root;
constraint_AST = (AST)astFactory.make( (new ASTArray(4)).add(astFactory.create(tmp71_AST)).add(dright_AST).add(astFactory.create(LT,"<")).add(dleft_AST));
currentAST.root = constraint_AST;
currentAST.child = constraint_AST!=null &&constraint_AST.getFirstChild()!=null ?
constraint_AST.getFirstChild() : constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched341 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==CONSTRAINT))) {
AST __t341 = _t;
synPredMatched341 = true;
inputState.guessing++;
try {
{
AST __t340 = _t;
ASTPair __currentAST340 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,LITERAL_not);
_t = _t.getNextSibling();
match(_t,LITERAL_like);
_t = _t.getNextSibling();
currentAST = __currentAST340;
_t = __t340;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched341 = false;
}
_t = __t341;
inputState.guessing--;
}
if ( synPredMatched341 ) {
AST __t342 = _t;
AST tmp73_AST = null;
AST tmp73_AST_in = null;
tmp73_AST = astFactory.create((AST)_t);
tmp73_AST_in = (AST)_t;
ASTPair __currentAST342 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
eleft = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
eleft_AST = (AST)returnAST;
AST tmp74_AST_in = null;
match(_t,LITERAL_not);
_t = _t.getNextSibling();
elike = (AST)_t;
AST elike_AST_in = null;
elike_AST = astFactory.create(elike);
match(_t,LITERAL_like);
_t = _t.getNextSibling();
eright = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
eright_AST = (AST)returnAST;
currentAST = __currentAST342;
_t = __t342;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
constraint_AST = (AST)currentAST.root;
constraint_AST = (AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(NOT_CONSTRAINT,"NOT_CONSTRAINT")).add((AST)astFactory.make( (new ASTArray(4)).add(astFactory.create(tmp73_AST)).add(eleft_AST).add(elike_AST).add(eright_AST))));
currentAST.root = constraint_AST;
currentAST.child = constraint_AST!=null &&constraint_AST.getFirstChild()!=null ?
constraint_AST.getFirstChild() : constraint_AST;
currentAST.advanceChildToEnd();
}
}
else if ((_t.getType()==CONSTRAINT)) {
AST __t343 = _t;
AST tmp75_AST = null;
AST tmp75_AST_in = null;
tmp75_AST = astFactory.create((AST)_t);
tmp75_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp75_AST);
ASTPair __currentAST343 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
comparison_op(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST343;
_t = __t343;
_t = _t.getNextSibling();
constraint_AST = (AST)currentAST.root;
}
else {
throw new NoViableAltException(_t);
}
}}}}
returnAST = constraint_AST;
_retTree = _t;
}
public final void not_constraint(AST _t) throws RecognitionException {
AST not_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST not_constraint_AST = null;
AST a_AST = null;
AST a = null;
AST b_AST = null;
AST b = null;
AST c_AST = null;
AST c = null;
AST e_AST = null;
AST e = null;
AST f_AST = null;
AST f = null;
boolean synPredMatched353 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==NOT_CONSTRAINT))) {
AST __t353 = _t;
synPredMatched353 = true;
inputState.guessing++;
try {
{
AST __t352 = _t;
ASTPair __currentAST352 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
match(_t,NOT_CONSTRAINT);
_t = _t.getNextSibling();
currentAST = __currentAST352;
_t = __t352;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched353 = false;
}
_t = __t353;
inputState.guessing--;
}
if ( synPredMatched353 ) {
AST __t354 = _t;
AST tmp76_AST = null;
AST tmp76_AST_in = null;
tmp76_AST = astFactory.create((AST)_t);
tmp76_AST_in = (AST)_t;
ASTPair __currentAST354 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
AST __t355 = _t;
AST tmp77_AST = null;
AST tmp77_AST_in = null;
tmp77_AST = astFactory.create((AST)_t);
tmp77_AST_in = (AST)_t;
ASTPair __currentAST355 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
a = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
a_AST = (AST)returnAST;
currentAST = __currentAST355;
_t = __t355;
_t = _t.getNextSibling();
currentAST = __currentAST354;
_t = __t354;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
not_constraint_AST = (AST)currentAST.root;
not_constraint_AST = a_AST;
currentAST.root = not_constraint_AST;
currentAST.child = not_constraint_AST!=null &¬_constraint_AST.getFirstChild()!=null ?
not_constraint_AST.getFirstChild() : not_constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched359 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==NOT_CONSTRAINT))) {
AST __t359 = _t;
synPredMatched359 = true;
inputState.guessing++;
try {
{
AST __t357 = _t;
ASTPair __currentAST357 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
AST __t358 = _t;
ASTPair __currentAST358 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST358;
_t = __t358;
_t = _t.getNextSibling();
currentAST = __currentAST357;
_t = __t357;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched359 = false;
}
_t = __t359;
inputState.guessing--;
}
if ( synPredMatched359 ) {
AST __t360 = _t;
AST tmp78_AST = null;
AST tmp78_AST_in = null;
tmp78_AST = astFactory.create((AST)_t);
tmp78_AST_in = (AST)_t;
ASTPair __currentAST360 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
AST __t361 = _t;
AST tmp79_AST = null;
AST tmp79_AST_in = null;
tmp79_AST = astFactory.create((AST)_t);
tmp79_AST_in = (AST)_t;
ASTPair __currentAST361 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
b = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
b_AST = (AST)returnAST;
c = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
c_AST = (AST)returnAST;
currentAST = __currentAST361;
_t = __t361;
_t = _t.getNextSibling();
currentAST = __currentAST360;
_t = __t360;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
not_constraint_AST = (AST)currentAST.root;
not_constraint_AST = (AST)astFactory.make( (new ASTArray(3)).add(astFactory.create(AND_CONSTRAINT_SET,"AND_CONSTRAINT_SET")).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp78_AST)).add(b_AST))).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp78_AST)).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp79_AST)).add(c_AST))))));
currentAST.root = not_constraint_AST;
currentAST.child = not_constraint_AST!=null &¬_constraint_AST.getFirstChild()!=null ?
not_constraint_AST.getFirstChild() : not_constraint_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched365 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==NOT_CONSTRAINT))) {
AST __t365 = _t;
synPredMatched365 = true;
inputState.guessing++;
try {
{
AST __t363 = _t;
ASTPair __currentAST363 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
AST __t364 = _t;
ASTPair __currentAST364 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST364;
_t = __t364;
_t = _t.getNextSibling();
currentAST = __currentAST363;
_t = __t363;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched365 = false;
}
_t = __t365;
inputState.guessing--;
}
if ( synPredMatched365 ) {
AST __t366 = _t;
AST tmp80_AST = null;
AST tmp80_AST_in = null;
tmp80_AST = astFactory.create((AST)_t);
tmp80_AST_in = (AST)_t;
ASTPair __currentAST366 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
AST __t367 = _t;
AST tmp81_AST = null;
AST tmp81_AST_in = null;
tmp81_AST = astFactory.create((AST)_t);
tmp81_AST_in = (AST)_t;
ASTPair __currentAST367 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
e = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
e_AST = (AST)returnAST;
f = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
f_AST = (AST)returnAST;
currentAST = __currentAST367;
_t = __t367;
_t = _t.getNextSibling();
currentAST = __currentAST366;
_t = __t366;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
not_constraint_AST = (AST)currentAST.root;
not_constraint_AST = (AST)astFactory.make( (new ASTArray(3)).add(astFactory.create(OR_CONSTRAINT_SET,"OR_CONSTRAINT_SET")).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp80_AST)).add(e_AST))).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp80_AST)).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp81_AST)).add(f_AST))))));
currentAST.root = not_constraint_AST;
currentAST.child = not_constraint_AST!=null &¬_constraint_AST.getFirstChild()!=null ?
not_constraint_AST.getFirstChild() : not_constraint_AST;
currentAST.advanceChildToEnd();
}
}
else if ((_t.getType()==NOT_CONSTRAINT)) {
AST __t368 = _t;
AST tmp82_AST = null;
AST tmp82_AST_in = null;
tmp82_AST = astFactory.create((AST)_t);
tmp82_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp82_AST);
ASTPair __currentAST368 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST368;
_t = __t368;
_t = _t.getNextSibling();
not_constraint_AST = (AST)currentAST.root;
}
else {
throw new NoViableAltException(_t);
}
}}
returnAST = not_constraint_AST;
_retTree = _t;
}
public final void and_constraint_set(AST _t) throws RecognitionException {
AST and_constraint_set_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST and_constraint_set_AST = null;
AST ta = null;
AST ta_AST = null;
AST a_AST = null;
AST a = null;
AST b_AST = null;
AST b = null;
AST tc = null;
AST tc_AST = null;
AST d_AST = null;
AST d = null;
AST e_AST = null;
AST e = null;
AST f_AST = null;
AST f = null;
AST td = null;
AST td_AST = null;
AST g_AST = null;
AST g = null;
AST h_AST = null;
AST h = null;
AST te = null;
AST te_AST = null;
AST tf = null;
AST tf_AST = null;
AST z_AST = null;
AST z = null;
boolean synPredMatched413 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==AND_CONSTRAINT_SET))) {
AST __t413 = _t;
synPredMatched413 = true;
inputState.guessing++;
try {
{
AST __t412 = _t;
ASTPair __currentAST412 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
match(_t,AND_CONSTRAINT_SET);
_t = _t.getNextSibling();
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST412;
_t = __t412;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched413 = false;
}
_t = __t413;
inputState.guessing--;
}
if ( synPredMatched413 ) {
AST __t414 = _t;
ta = _t==ASTNULL ? null :(AST)_t;
AST ta_AST_in = null;
ta_AST = astFactory.create(ta);
ASTPair __currentAST414 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
AST __t415 = _t;
AST tmp83_AST = null;
AST tmp83_AST_in = null;
tmp83_AST = astFactory.create((AST)_t);
tmp83_AST_in = (AST)_t;
ASTPair __currentAST415 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
a = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
a_AST = (AST)returnAST;
currentAST = __currentAST415;
_t = __t415;
_t = _t.getNextSibling();
b = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
b_AST = (AST)returnAST;
currentAST = __currentAST414;
_t = __t414;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
and_constraint_set_AST = (AST)currentAST.root;
and_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(ta_AST).add(a_AST).add(b_AST));
currentAST.root = and_constraint_set_AST;
currentAST.child = and_constraint_set_AST!=null &&and_constraint_set_AST.getFirstChild()!=null ?
and_constraint_set_AST.getFirstChild() : and_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched418 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==AND_CONSTRAINT_SET))) {
AST __t418 = _t;
synPredMatched418 = true;
inputState.guessing++;
try {
{
AST __t417 = _t;
ASTPair __currentAST417 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notand(_t);
_t = _retTree;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getNextSibling();
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST417;
_t = __t417;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched418 = false;
}
_t = __t418;
inputState.guessing--;
}
if ( synPredMatched418 ) {
AST __t419 = _t;
tc = _t==ASTNULL ? null :(AST)_t;
AST tc_AST_in = null;
tc_AST = astFactory.create(tc);
ASTPair __currentAST419 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
d = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notand(_t);
_t = _retTree;
d_AST = (AST)returnAST;
AST __t420 = _t;
AST tmp84_AST = null;
AST tmp84_AST_in = null;
tmp84_AST = astFactory.create((AST)_t);
tmp84_AST_in = (AST)_t;
ASTPair __currentAST420 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
e = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
e_AST = (AST)returnAST;
currentAST = __currentAST420;
_t = __t420;
_t = _t.getNextSibling();
f = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
f_AST = (AST)returnAST;
currentAST = __currentAST419;
_t = __t419;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
and_constraint_set_AST = (AST)currentAST.root;
and_constraint_set_AST = (AST)astFactory.make( (new ASTArray(4)).add(tc_AST).add(d_AST).add(e_AST).add(f_AST));
currentAST.root = and_constraint_set_AST;
currentAST.child = and_constraint_set_AST!=null &&and_constraint_set_AST.getFirstChild()!=null ?
and_constraint_set_AST.getFirstChild() : and_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched423 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==AND_CONSTRAINT_SET))) {
AST __t423 = _t;
synPredMatched423 = true;
inputState.guessing++;
try {
{
AST __t422 = _t;
ASTPair __currentAST422 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notand(_t);
_t = _retTree;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getNextSibling();
currentAST = __currentAST422;
_t = __t422;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched423 = false;
}
_t = __t423;
inputState.guessing--;
}
if ( synPredMatched423 ) {
AST __t424 = _t;
td = _t==ASTNULL ? null :(AST)_t;
AST td_AST_in = null;
td_AST = astFactory.create(td);
ASTPair __currentAST424 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
g = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notand(_t);
_t = _retTree;
g_AST = (AST)returnAST;
AST __t425 = _t;
AST tmp85_AST = null;
AST tmp85_AST_in = null;
tmp85_AST = astFactory.create((AST)_t);
tmp85_AST_in = (AST)_t;
ASTPair __currentAST425 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
h = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
h_AST = (AST)returnAST;
currentAST = __currentAST425;
_t = __t425;
_t = _t.getNextSibling();
currentAST = __currentAST424;
_t = __t424;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
and_constraint_set_AST = (AST)currentAST.root;
and_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(td_AST).add(g_AST).add(h_AST));
currentAST.root = and_constraint_set_AST;
currentAST.child = and_constraint_set_AST!=null &&and_constraint_set_AST.getFirstChild()!=null ?
and_constraint_set_AST.getFirstChild() : and_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched428 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==AND_CONSTRAINT_SET))) {
AST __t428 = _t;
synPredMatched428 = true;
inputState.guessing++;
try {
{
AST __t427 = _t;
ASTPair __currentAST427 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST427;
_t = __t427;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched428 = false;
}
_t = __t428;
inputState.guessing--;
}
if ( synPredMatched428 ) {
AST __t429 = _t;
te = _t==ASTNULL ? null :(AST)_t;
AST te_AST_in = null;
te_AST = astFactory.create(te);
astFactory.addASTChild(currentAST, te_AST);
ASTPair __currentAST429 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
{
int _cnt431=0;
_loop431:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt431>=1 ) { break _loop431; } else {throw new NoViableAltException(_t);}
}
_cnt431++;
} while (true);
}
currentAST = __currentAST429;
_t = __t429;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
}
and_constraint_set_AST = (AST)currentAST.root;
}
else if ((_t.getType()==AND_CONSTRAINT_SET)) {
AST __t432 = _t;
tf = _t==ASTNULL ? null :(AST)_t;
AST tf_AST_in = null;
tf_AST = astFactory.create(tf);
ASTPair __currentAST432 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
z = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
z_AST = (AST)returnAST;
currentAST = __currentAST432;
_t = __t432;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
and_constraint_set_AST = (AST)currentAST.root;
and_constraint_set_AST = z_AST;
currentAST.root = and_constraint_set_AST;
currentAST.child = and_constraint_set_AST!=null &&and_constraint_set_AST.getFirstChild()!=null ?
and_constraint_set_AST.getFirstChild() : and_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
throw new NoViableAltException(_t);
}
}}}
returnAST = and_constraint_set_AST;
_retTree = _t;
}
public final void or_constraint_set(AST _t) throws RecognitionException {
AST or_constraint_set_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST or_constraint_set_AST = null;
AST ta = null;
AST ta_AST = null;
AST a_AST = null;
AST a = null;
AST b_AST = null;
AST b = null;
AST tc = null;
AST tc_AST = null;
AST d_AST = null;
AST d = null;
AST e_AST = null;
AST e = null;
AST f_AST = null;
AST f = null;
AST td = null;
AST td_AST = null;
AST g_AST = null;
AST g = null;
AST h_AST = null;
AST h = null;
AST te = null;
AST te_AST = null;
AST tf = null;
AST tf_AST = null;
AST i_AST = null;
AST i = null;
AST j_AST = null;
AST j = null;
AST k_AST = null;
AST k = null;
AST tg = null;
AST tg_AST = null;
AST l_AST = null;
AST l = null;
AST th = null;
AST th_AST = null;
AST m_AST = null;
AST m = null;
AST n_AST = null;
AST n = null;
AST o_AST = null;
AST o = null;
AST ti = null;
AST ti_AST = null;
AST p_AST = null;
AST p = null;
AST tj = null;
AST tj_AST = null;
AST q_AST = null;
AST q = null;
AST r_AST = null;
AST r = null;
AST z_AST = null;
AST z = null;
boolean synPredMatched372 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t372 = _t;
synPredMatched372 = true;
inputState.guessing++;
try {
{
AST __t371 = _t;
ASTPair __currentAST371 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
match(_t,OR_CONSTRAINT_SET);
_t = _t.getNextSibling();
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST371;
_t = __t371;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched372 = false;
}
_t = __t372;
inputState.guessing--;
}
if ( synPredMatched372 ) {
AST __t373 = _t;
ta = _t==ASTNULL ? null :(AST)_t;
AST ta_AST_in = null;
ta_AST = astFactory.create(ta);
ASTPair __currentAST373 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
AST __t374 = _t;
AST tmp86_AST = null;
AST tmp86_AST_in = null;
tmp86_AST = astFactory.create((AST)_t);
tmp86_AST_in = (AST)_t;
ASTPair __currentAST374 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
a = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
a_AST = (AST)returnAST;
currentAST = __currentAST374;
_t = __t374;
_t = _t.getNextSibling();
b = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
b_AST = (AST)returnAST;
currentAST = __currentAST373;
_t = __t373;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(ta_AST).add(a_AST).add(b_AST));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched377 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t377 = _t;
synPredMatched377 = true;
inputState.guessing++;
try {
{
AST __t376 = _t;
ASTPair __currentAST376 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notor(_t);
_t = _retTree;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getNextSibling();
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST376;
_t = __t376;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched377 = false;
}
_t = __t377;
inputState.guessing--;
}
if ( synPredMatched377 ) {
AST __t378 = _t;
tc = _t==ASTNULL ? null :(AST)_t;
AST tc_AST_in = null;
tc_AST = astFactory.create(tc);
ASTPair __currentAST378 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
d = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notor(_t);
_t = _retTree;
d_AST = (AST)returnAST;
AST __t379 = _t;
AST tmp87_AST = null;
AST tmp87_AST_in = null;
tmp87_AST = astFactory.create((AST)_t);
tmp87_AST_in = (AST)_t;
ASTPair __currentAST379 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
e = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
e_AST = (AST)returnAST;
currentAST = __currentAST379;
_t = __t379;
_t = _t.getNextSibling();
f = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
f_AST = (AST)returnAST;
currentAST = __currentAST378;
_t = __t378;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(4)).add(tc_AST).add(d_AST).add(e_AST).add(f_AST));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched382 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t382 = _t;
synPredMatched382 = true;
inputState.guessing++;
try {
{
AST __t381 = _t;
ASTPair __currentAST381 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notor(_t);
_t = _retTree;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getNextSibling();
currentAST = __currentAST381;
_t = __t381;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched382 = false;
}
_t = __t382;
inputState.guessing--;
}
if ( synPredMatched382 ) {
AST __t383 = _t;
td = _t==ASTNULL ? null :(AST)_t;
AST td_AST_in = null;
td_AST = astFactory.create(td);
ASTPair __currentAST383 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
g = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notor(_t);
_t = _retTree;
g_AST = (AST)returnAST;
AST __t384 = _t;
AST tmp88_AST = null;
AST tmp88_AST_in = null;
tmp88_AST = astFactory.create((AST)_t);
tmp88_AST_in = (AST)_t;
ASTPair __currentAST384 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
h = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
h_AST = (AST)returnAST;
currentAST = __currentAST384;
_t = __t384;
_t = _t.getNextSibling();
currentAST = __currentAST383;
_t = __t383;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(td_AST).add(g_AST).add(h_AST));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched388 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t388 = _t;
synPredMatched388 = true;
inputState.guessing++;
try {
{
AST __t386 = _t;
ASTPair __currentAST386 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
AST __t387 = _t;
ASTPair __currentAST387 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint_list(_t);
_t = _retTree;
currentAST = __currentAST387;
_t = __t387;
_t = _t.getNextSibling();
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST386;
_t = __t386;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched388 = false;
}
_t = __t388;
inputState.guessing--;
}
if ( synPredMatched388 ) {
AST __t389 = _t;
te = _t==ASTNULL ? null :(AST)_t;
AST te_AST_in = null;
te_AST = astFactory.create(te);
ASTPair __currentAST389 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
AST __t390 = _t;
tf = _t==ASTNULL ? null :(AST)_t;
AST tf_AST_in = null;
tf_AST = astFactory.create(tf);
ASTPair __currentAST390 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
i = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
i_AST = (AST)returnAST;
j = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
j_AST = (AST)returnAST;
currentAST = __currentAST390;
_t = __t390;
_t = _t.getNextSibling();
k = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
k_AST = (AST)returnAST;
currentAST = __currentAST389;
_t = __t389;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
AST te2_AST = astFactory.create(te);
AST k2_AST = astFactory.dupList(k_AST);
AST tf2_AST = astFactory.create(tf);
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(tf_AST).add((AST)astFactory.make( (new ASTArray(3)).add(te_AST).add(i_AST).add(k_AST))).add((AST)astFactory.make( (new ASTArray(3)).add(te2_AST).add((AST)astFactory.make( (new ASTArray(2)).add(tf2_AST).add(j_AST))).add(k2_AST))));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched394 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t394 = _t;
synPredMatched394 = true;
inputState.guessing++;
try {
{
AST __t392 = _t;
ASTPair __currentAST392 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notand(_t);
_t = _retTree;
AST __t393 = _t;
ASTPair __currentAST393 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST393;
_t = __t393;
_t = _t.getNextSibling();
n_abstract_constraint_list(_t);
_t = _retTree;
currentAST = __currentAST392;
_t = __t392;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched394 = false;
}
_t = __t394;
inputState.guessing--;
}
if ( synPredMatched394 ) {
AST __t395 = _t;
tg = _t==ASTNULL ? null :(AST)_t;
AST tg_AST_in = null;
tg_AST = astFactory.create(tg);
ASTPair __currentAST395 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
l = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notand(_t);
_t = _retTree;
l_AST = (AST)returnAST;
AST __t396 = _t;
th = _t==ASTNULL ? null :(AST)_t;
AST th_AST_in = null;
th_AST = astFactory.create(th);
ASTPair __currentAST396 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
m = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
m_AST = (AST)returnAST;
n = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
n_AST = (AST)returnAST;
currentAST = __currentAST396;
_t = __t396;
_t = _t.getNextSibling();
o = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
o_AST = (AST)returnAST;
currentAST = __currentAST395;
_t = __t395;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
AST tg2_AST = astFactory.create(tg);
AST l2_AST = astFactory.dupList(l_AST);
AST o2_AST = astFactory.dupList(o_AST);
AST th2_AST = astFactory.create(th);
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(th_AST).add((AST)astFactory.make( (new ASTArray(4)).add(tg_AST).add(l_AST).add(m_AST).add(o_AST))).add((AST)astFactory.make( (new ASTArray(4)).add(tg2_AST).add(l2_AST).add((AST)astFactory.make( (new ASTArray(2)).add(th2_AST).add(n_AST))).add(o2_AST))));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched400 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t400 = _t;
synPredMatched400 = true;
inputState.guessing++;
try {
{
AST __t398 = _t;
ASTPair __currentAST398 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint_list_notand(_t);
_t = _retTree;
AST __t399 = _t;
ASTPair __currentAST399 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST399;
_t = __t399;
_t = _t.getNextSibling();
currentAST = __currentAST398;
_t = __t398;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched400 = false;
}
_t = __t400;
inputState.guessing--;
}
if ( synPredMatched400 ) {
AST __t401 = _t;
ti = _t==ASTNULL ? null :(AST)_t;
AST ti_AST_in = null;
ti_AST = astFactory.create(ti);
ASTPair __currentAST401 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
p = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list_notand(_t);
_t = _retTree;
p_AST = (AST)returnAST;
AST __t402 = _t;
tj = _t==ASTNULL ? null :(AST)_t;
AST tj_AST_in = null;
tj_AST = astFactory.create(tj);
ASTPair __currentAST402 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
q = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
q_AST = (AST)returnAST;
r = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint_list(_t);
_t = _retTree;
r_AST = (AST)returnAST;
currentAST = __currentAST402;
_t = __t402;
_t = _t.getNextSibling();
currentAST = __currentAST401;
_t = __t401;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
AST ti2_AST = astFactory.create(ti);
AST p2_AST = astFactory.dupList(p_AST);
AST tj2_AST = astFactory.create(tj);
or_constraint_set_AST = (AST)astFactory.make( (new ASTArray(3)).add(tj_AST).add((AST)astFactory.make( (new ASTArray(3)).add(ti_AST).add(p_AST).add(q_AST))).add((AST)astFactory.make( (new ASTArray(3)).add(ti2_AST).add(p2_AST).add((AST)astFactory.make( (new ASTArray(2)).add(tj2_AST).add(r_AST))))));
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
boolean synPredMatched405 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==OR_CONSTRAINT_SET))) {
AST __t405 = _t;
synPredMatched405 = true;
inputState.guessing++;
try {
{
AST __t404 = _t;
ASTPair __currentAST404 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
n_abstract_constraint(_t);
_t = _retTree;
currentAST = __currentAST404;
_t = __t404;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched405 = false;
}
_t = __t405;
inputState.guessing--;
}
if ( synPredMatched405 ) {
AST __t406 = _t;
AST tmp89_AST = null;
AST tmp89_AST_in = null;
tmp89_AST = astFactory.create((AST)_t);
tmp89_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp89_AST);
ASTPair __currentAST406 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
{
int _cnt408=0;
_loop408:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt408>=1 ) { break _loop408; } else {throw new NoViableAltException(_t);}
}
_cnt408++;
} while (true);
}
currentAST = __currentAST406;
_t = __t406;
_t = _t.getNextSibling();
or_constraint_set_AST = (AST)currentAST.root;
}
else if ((_t.getType()==OR_CONSTRAINT_SET)) {
AST __t409 = _t;
AST tmp90_AST = null;
AST tmp90_AST_in = null;
tmp90_AST = astFactory.create((AST)_t);
tmp90_AST_in = (AST)_t;
ASTPair __currentAST409 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
z = _t==ASTNULL ? null : (AST)_t;
n_abstract_constraint(_t);
_t = _retTree;
z_AST = (AST)returnAST;
currentAST = __currentAST409;
_t = __t409;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
or_constraint_set_AST = (AST)currentAST.root;
or_constraint_set_AST = z_AST;
currentAST.root = or_constraint_set_AST;
currentAST.child = or_constraint_set_AST!=null &&or_constraint_set_AST.getFirstChild()!=null ?
or_constraint_set_AST.getFirstChild() : or_constraint_set_AST;
currentAST.advanceChildToEnd();
}
}
else {
throw new NoViableAltException(_t);
}
}}}}}}
returnAST = or_constraint_set_AST;
_retTree = _t;
}
public final void subquery_constraint(AST _t) throws RecognitionException {
AST subquery_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST subquery_constraint_AST = null;
AST __t434 = _t;
AST tmp91_AST = null;
AST tmp91_AST_in = null;
tmp91_AST = astFactory.create((AST)_t);
tmp91_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp91_AST);
ASTPair __currentAST434 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,SUBQUERY_CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
sql(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST434;
_t = __t434;
_t = _t.getNextSibling();
subquery_constraint_AST = (AST)currentAST.root;
returnAST = subquery_constraint_AST;
_retTree = _t;
}
public final void inlist_constraint(AST _t) throws RecognitionException {
AST inlist_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST inlist_constraint_AST = null;
AST __t436 = _t;
AST tmp92_AST = null;
AST tmp92_AST_in = null;
tmp92_AST = astFactory.create((AST)_t);
tmp92_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp92_AST);
ASTPair __currentAST436 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,INLIST_CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
int _cnt438=0;
_loop438:
do {
if (_t==null) _t=ASTNULL;
if ((_t.getType()==CONSTANT)) {
constant(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt438>=1 ) { break _loop438; } else {throw new NoViableAltException(_t);}
}
_cnt438++;
} while (true);
}
currentAST = __currentAST436;
_t = __t436;
_t = _t.getNextSibling();
inlist_constraint_AST = (AST)currentAST.root;
returnAST = inlist_constraint_AST;
_retTree = _t;
}
public final void null_constraint(AST _t) throws RecognitionException {
AST null_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST null_constraint_AST = null;
AST v_AST = null;
AST v = null;
boolean synPredMatched347 = false;
if (_t==null) _t=ASTNULL;
if (((_t.getType()==NULL_CONSTRAINT))) {
AST __t347 = _t;
synPredMatched347 = true;
inputState.guessing++;
try {
{
AST __t346 = _t;
ASTPair __currentAST346 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NULL_CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
match(_t,LITERAL_not);
_t = _t.getNextSibling();
currentAST = __currentAST346;
_t = __t346;
_t = _t.getNextSibling();
}
}
catch (RecognitionException pe) {
synPredMatched347 = false;
}
_t = __t347;
inputState.guessing--;
}
if ( synPredMatched347 ) {
AST __t348 = _t;
AST tmp93_AST = null;
AST tmp93_AST_in = null;
tmp93_AST = astFactory.create((AST)_t);
tmp93_AST_in = (AST)_t;
ASTPair __currentAST348 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NULL_CONSTRAINT);
_t = _t.getFirstChild();
v = _t==ASTNULL ? null : (AST)_t;
abstract_value(_t);
_t = _retTree;
v_AST = (AST)returnAST;
AST tmp94_AST_in = null;
match(_t,LITERAL_not);
_t = _t.getNextSibling();
currentAST = __currentAST348;
_t = __t348;
_t = _t.getNextSibling();
if ( inputState.guessing==0 ) {
null_constraint_AST = (AST)currentAST.root;
null_constraint_AST = (AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(NOT_CONSTRAINT,"NOT_CONSTRAINT")).add((AST)astFactory.make( (new ASTArray(2)).add(astFactory.create(tmp93_AST)).add(v_AST))));
currentAST.root = null_constraint_AST;
currentAST.child = null_constraint_AST!=null &&null_constraint_AST.getFirstChild()!=null ?
null_constraint_AST.getFirstChild() : null_constraint_AST;
currentAST.advanceChildToEnd();
}
}
else if ((_t.getType()==NULL_CONSTRAINT)) {
AST __t349 = _t;
AST tmp95_AST = null;
AST tmp95_AST_in = null;
tmp95_AST = astFactory.create((AST)_t);
tmp95_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp95_AST);
ASTPair __currentAST349 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NULL_CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST349;
_t = __t349;
_t = _t.getNextSibling();
null_constraint_AST = (AST)currentAST.root;
}
else {
throw new NoViableAltException(_t);
}
returnAST = null_constraint_AST;
_retTree = _t;
}
public final void comparison_op(AST _t) throws RecognitionException {
AST comparison_op_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST comparison_op_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case EQ:
{
AST tmp96_AST = null;
AST tmp96_AST_in = null;
tmp96_AST = astFactory.create((AST)_t);
tmp96_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp96_AST);
match(_t,EQ);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case LT:
{
AST tmp97_AST = null;
AST tmp97_AST_in = null;
tmp97_AST = astFactory.create((AST)_t);
tmp97_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp97_AST);
match(_t,LT);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case GT:
{
AST tmp98_AST = null;
AST tmp98_AST_in = null;
tmp98_AST = astFactory.create((AST)_t);
tmp98_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp98_AST);
match(_t,GT);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case NOT_EQ:
{
AST tmp99_AST = null;
AST tmp99_AST_in = null;
tmp99_AST = astFactory.create((AST)_t);
tmp99_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp99_AST);
match(_t,NOT_EQ);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case LE:
{
AST tmp100_AST = null;
AST tmp100_AST_in = null;
tmp100_AST = astFactory.create((AST)_t);
tmp100_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp100_AST);
match(_t,LE);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case GE:
{
AST tmp101_AST = null;
AST tmp101_AST_in = null;
tmp101_AST = astFactory.create((AST)_t);
tmp101_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp101_AST);
match(_t,GE);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case GORNULL:
{
AST tmp102_AST = null;
AST tmp102_AST_in = null;
tmp102_AST = astFactory.create((AST)_t);
tmp102_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp102_AST);
match(_t,GORNULL);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case LITERAL_like:
{
AST tmp103_AST = null;
AST tmp103_AST_in = null;
tmp103_AST = astFactory.create((AST)_t);
tmp103_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp103_AST);
match(_t,LITERAL_like);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
case LITERAL_not:
{
AST tmp104_AST = null;
AST tmp104_AST_in = null;
tmp104_AST = astFactory.create((AST)_t);
tmp104_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp104_AST);
match(_t,LITERAL_not);
_t = _t.getNextSibling();
AST tmp105_AST = null;
AST tmp105_AST_in = null;
tmp105_AST = astFactory.create((AST)_t);
tmp105_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp105_AST);
match(_t,LITERAL_like);
_t = _t.getNextSibling();
comparison_op_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = comparison_op_AST;
_retTree = _t;
}
public final void n_abstract_constraint(AST _t) throws RecognitionException {
AST n_abstract_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_abstract_constraint_AST = null;
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
n_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case NOT_CONSTRAINT:
{
n_not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case AND_CONSTRAINT_SET:
{
n_and_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case OR_CONSTRAINT_SET:
{
n_or_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
case NULL_CONSTRAINT:
{
n_null_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
n_abstract_constraint_AST = (AST)currentAST.root;
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
returnAST = n_abstract_constraint_AST;
_retTree = _t;
}
public final void n_abstract_constraint_list(AST _t) throws RecognitionException {
AST n_abstract_constraint_list_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_abstract_constraint_list_AST = null;
{
int _cnt467=0;
_loop467:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
n_abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt467>=1 ) { break _loop467; } else {throw new NoViableAltException(_t);}
}
_cnt467++;
} while (true);
}
n_abstract_constraint_list_AST = (AST)currentAST.root;
returnAST = n_abstract_constraint_list_AST;
_retTree = _t;
}
public final void n_abstract_constraint_list_notor(AST _t) throws RecognitionException {
AST n_abstract_constraint_list_notor_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_abstract_constraint_list_notor_AST = null;
{
int _cnt473=0;
_loop473:
do {
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
n_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NOT_CONSTRAINT:
{
n_not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case AND_CONSTRAINT_SET:
{
n_and_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NULL_CONSTRAINT:
{
n_null_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
default:
{
if ( _cnt473>=1 ) { break _loop473; } else {throw new NoViableAltException(_t);}
}
}
_cnt473++;
} while (true);
}
n_abstract_constraint_list_notor_AST = (AST)currentAST.root;
returnAST = n_abstract_constraint_list_notor_AST;
_retTree = _t;
}
public final void n_abstract_constraint_list_notand(AST _t) throws RecognitionException {
AST n_abstract_constraint_list_notand_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_abstract_constraint_list_notand_AST = null;
{
int _cnt470=0;
_loop470:
do {
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
n_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NOT_CONSTRAINT:
{
n_not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case OR_CONSTRAINT_SET:
{
n_or_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NULL_CONSTRAINT:
{
n_null_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
default:
{
if ( _cnt470>=1 ) { break _loop470; } else {throw new NoViableAltException(_t);}
}
}
_cnt470++;
} while (true);
}
n_abstract_constraint_list_notand_AST = (AST)currentAST.root;
returnAST = n_abstract_constraint_list_notand_AST;
_retTree = _t;
}
public final void abstract_constraint_list(AST _t) throws RecognitionException {
AST abstract_constraint_list_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_constraint_list_AST = null;
{
int _cnt442=0;
_loop442:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt442>=1 ) { break _loop442; } else {throw new NoViableAltException(_t);}
}
_cnt442++;
} while (true);
}
abstract_constraint_list_AST = (AST)currentAST.root;
returnAST = abstract_constraint_list_AST;
_retTree = _t;
}
public final void abstract_constraint_list_notand(AST _t) throws RecognitionException {
AST abstract_constraint_list_notand_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_constraint_list_notand_AST = null;
{
int _cnt445=0;
_loop445:
do {
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NOT_CONSTRAINT:
{
not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case OR_CONSTRAINT_SET:
{
or_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
default:
{
if ( _cnt445>=1 ) { break _loop445; } else {throw new NoViableAltException(_t);}
}
}
_cnt445++;
} while (true);
}
abstract_constraint_list_notand_AST = (AST)currentAST.root;
returnAST = abstract_constraint_list_notand_AST;
_retTree = _t;
}
public final void abstract_constraint_list_notor(AST _t) throws RecognitionException {
AST abstract_constraint_list_notor_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST abstract_constraint_list_notor_AST = null;
{
int _cnt448=0;
_loop448:
do {
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case CONSTRAINT:
{
constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case NOT_CONSTRAINT:
{
not_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case AND_CONSTRAINT_SET:
{
and_constraint_set(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case SUBQUERY_CONSTRAINT:
{
subquery_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
case INLIST_CONSTRAINT:
{
inlist_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
break;
}
default:
{
if ( _cnt448>=1 ) { break _loop448; } else {throw new NoViableAltException(_t);}
}
}
_cnt448++;
} while (true);
}
abstract_constraint_list_notor_AST = (AST)currentAST.root;
returnAST = abstract_constraint_list_notor_AST;
_retTree = _t;
}
public final void n_constraint(AST _t) throws RecognitionException {
AST n_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_constraint_AST = null;
AST __t451 = _t;
AST tmp106_AST = null;
AST tmp106_AST_in = null;
tmp106_AST = astFactory.create((AST)_t);
tmp106_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp106_AST);
ASTPair __currentAST451 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
comparison_op(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST451;
_t = __t451;
_t = _t.getNextSibling();
n_constraint_AST = (AST)currentAST.root;
returnAST = n_constraint_AST;
_retTree = _t;
}
public final void n_not_constraint(AST _t) throws RecognitionException {
AST n_not_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_not_constraint_AST = null;
AST __t456 = _t;
AST tmp107_AST = null;
AST tmp107_AST_in = null;
tmp107_AST = astFactory.create((AST)_t);
tmp107_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp107_AST);
ASTPair __currentAST456 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NOT_CONSTRAINT);
_t = _t.getFirstChild();
n_abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
currentAST = __currentAST456;
_t = __t456;
_t = _t.getNextSibling();
n_not_constraint_AST = (AST)currentAST.root;
returnAST = n_not_constraint_AST;
_retTree = _t;
}
public final void n_and_constraint_set(AST _t) throws RecognitionException {
AST n_and_constraint_set_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_and_constraint_set_AST = null;
AST __t458 = _t;
AST tmp108_AST = null;
AST tmp108_AST_in = null;
tmp108_AST = astFactory.create((AST)_t);
tmp108_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp108_AST);
ASTPair __currentAST458 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,AND_CONSTRAINT_SET);
_t = _t.getFirstChild();
{
int _cnt460=0;
_loop460:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
n_abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt460>=1 ) { break _loop460; } else {throw new NoViableAltException(_t);}
}
_cnt460++;
} while (true);
}
currentAST = __currentAST458;
_t = __t458;
_t = _t.getNextSibling();
n_and_constraint_set_AST = (AST)currentAST.root;
returnAST = n_and_constraint_set_AST;
_retTree = _t;
}
public final void n_or_constraint_set(AST _t) throws RecognitionException {
AST n_or_constraint_set_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_or_constraint_set_AST = null;
AST __t462 = _t;
AST tmp109_AST = null;
AST tmp109_AST_in = null;
tmp109_AST = astFactory.create((AST)_t);
tmp109_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp109_AST);
ASTPair __currentAST462 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,OR_CONSTRAINT_SET);
_t = _t.getFirstChild();
{
int _cnt464=0;
_loop464:
do {
if (_t==null) _t=ASTNULL;
if (((_t.getType() >= CONSTRAINT && _t.getType() <= INLIST_CONSTRAINT))) {
n_abstract_constraint(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
}
else {
if ( _cnt464>=1 ) { break _loop464; } else {throw new NoViableAltException(_t);}
}
_cnt464++;
} while (true);
}
currentAST = __currentAST462;
_t = __t462;
_t = _t.getNextSibling();
n_or_constraint_set_AST = (AST)currentAST.root;
returnAST = n_or_constraint_set_AST;
_retTree = _t;
}
public final void n_null_constraint(AST _t) throws RecognitionException {
AST n_null_constraint_AST_in = (_t == ASTNULL) ? null : (AST)_t;
returnAST = null;
ASTPair currentAST = new ASTPair();
AST n_null_constraint_AST = null;
AST __t453 = _t;
AST tmp110_AST = null;
AST tmp110_AST_in = null;
tmp110_AST = astFactory.create((AST)_t);
tmp110_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp110_AST);
ASTPair __currentAST453 = currentAST.copy();
currentAST.root = currentAST.child;
currentAST.child = null;
match(_t,NULL_CONSTRAINT);
_t = _t.getFirstChild();
abstract_value(_t);
_t = _retTree;
astFactory.addASTChild(currentAST, returnAST);
{
if (_t==null) _t=ASTNULL;
switch ( _t.getType()) {
case LITERAL_not:
{
AST tmp111_AST = null;
AST tmp111_AST_in = null;
tmp111_AST = astFactory.create((AST)_t);
tmp111_AST_in = (AST)_t;
astFactory.addASTChild(currentAST, tmp111_AST);
match(_t,LITERAL_not);
_t = _t.getNextSibling();
break;
}
case 3:
{
break;
}
default:
{
throw new NoViableAltException(_t);
}
}
}
currentAST = __currentAST453;
_t = __t453;
_t = _t.getNextSibling();
n_null_constraint_AST = (AST)currentAST.root;
returnAST = n_null_constraint_AST;
_retTree = _t;
}
public static final String[] _tokenNames = {
"<0>",
"EOF",
"<2>",
"NULL_TREE_LOOKAHEAD",
"SQL_STATEMENT",
"SELECT_LIST",
"FROM_LIST",
"WHERE_CLAUSE",
"GROUP_CLAUSE",
"HAVING_CLAUSE",
"ORDER_CLAUSE",
"LIMIT_CLAUSE",
"SELECT_VALUE",
"TABLE_ALIAS",
"FIELD_ALIAS",
"TABLE",
"TABLE_NAME",
"SUBQUERY",
"CONSTANT",
"FIELD",
"FIELD_NAME",
"SAFE_FUNCTION",
"UNSAFE_FUNCTION",
"CONSTRAINT",
"NULL_CONSTRAINT",
"NOT_CONSTRAINT",
"AND_CONSTRAINT_SET",
"OR_CONSTRAINT_SET",
"SUBQUERY_CONSTRAINT",
"INLIST_CONSTRAINT",
"ORDER_DESC",
"\"explain\"",
"\"distinct\"",
"INTEGER",
"ALIAS",
"IDENTIFIER",
"QUOTED_STRING",
"ESCAPED_STRING",
"FLOAT",
"\"true\"",
"\"false\"",
"\"null\"",
"TYPECAST",
"\"boolean\"",
"\"real\"",
"\"double\"",
"\"smallint\"",
"\"integer\"",
"\"bigint\"",
"\"numeric\"",
"\"text\"",
"\"count\"",
"\"max\"",
"\"min\"",
"\"sum\"",
"\"avg\"",
"\"lower\"",
"\"upper\"",
"\"greatest\"",
"\"least\"",
"\"strpos\"",
"\"substr\"",
"\"coalesce\"",
"\"stddev\"",
"PLUS",
"PERCENT",
"ASTERISK",
"DIVIDE",
"POWER",
"MINUS",
"NOT_EQ",
"GE",
"LE",
"GT",
"\"not\"",
"\"like\"",
"EQ",
"LT",
"GORNULL",
"SEMI",
"\"union\"",
"\"select\"",
"\"all\"",
"COMMA",
"\"from\"",
"\"where\"",
"\"group\"",
"\"by\"",
"\"having\"",
"\"order\"",
"\"limit\"",
"\"offset\"",
"\"as\"",
"\"desc\"",
"OPEN_PAREN",
"CLOSE_PAREN",
"DOT",
"COLONTYPE",
"\"precision\"",
"\"or\"",
"\"is\"",
"\"and\"",
"\"in\"",
"AT_SIGN",
"OVERLAP",
"INSIDE",
"SURROUND",
"VERTBAR",
"WS"
};
private static final long[] mk_tokenSet_0() {
long[] data = { 4398053588992L, 0L};
return data;
}
public static final BitSet _tokenSet_0 = new BitSet(mk_tokenSet_0());
private static final long[] mk_tokenSet_1() {
long[] data = { 4399127330816L, 0L};
return data;
}
public static final BitSet _tokenSet_1 = new BitSet(mk_tokenSet_1());
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy