io.github.apexdevtools.apexparser.ApexParser Maven / Gradle / Ivy
The newest version!
// Generated from io/github/apexdevtools/apexparser/ApexParser.g4 by ANTLR 4.9.1
package io.github.apexdevtools.apexparser;
import org.antlr.v4.runtime.atn.*;
import org.antlr.v4.runtime.dfa.DFA;
import org.antlr.v4.runtime.*;
import org.antlr.v4.runtime.misc.*;
import org.antlr.v4.runtime.tree.*;
import java.util.List;
import java.util.Iterator;
import java.util.ArrayList;
@SuppressWarnings({"all", "warnings", "unchecked", "unused", "cast"})
public class ApexParser extends Parser {
static { RuntimeMetaData.checkVersion("4.9.1", RuntimeMetaData.VERSION); }
protected static final DFA[] _decisionToDFA;
protected static final PredictionContextCache _sharedContextCache =
new PredictionContextCache();
public static final int
ABSTRACT=1, AFTER=2, BEFORE=3, BREAK=4, CATCH=5, CLASS=6, CONTINUE=7,
DELETE=8, DO=9, ELSE=10, ENUM=11, EXTENDS=12, FINAL=13, FINALLY=14, FOR=15,
GET=16, GLOBAL=17, IF=18, IMPLEMENTS=19, INHERITED=20, INSERT=21, INSTANCEOF=22,
INTERFACE=23, MERGE=24, NEW=25, NULL=26, ON=27, OVERRIDE=28, PRIVATE=29,
PROTECTED=30, PUBLIC=31, RETURN=32, SYSTEMRUNAS=33, SET=34, SHARING=35,
STATIC=36, SUPER=37, SWITCH=38, TESTMETHOD=39, THIS=40, THROW=41, TRANSIENT=42,
TRIGGER=43, TRY=44, UNDELETE=45, UPDATE=46, UPSERT=47, VIRTUAL=48, VOID=49,
WEBSERVICE=50, WHEN=51, WHILE=52, WITH=53, WITHOUT=54, LIST=55, MAP=56,
SYSTEM=57, USER=58, SELECT=59, COUNT=60, FROM=61, AS=62, USING=63, SCOPE=64,
WHERE=65, ORDER=66, BY=67, LIMIT=68, SOQLAND=69, SOQLOR=70, NOT=71, AVG=72,
COUNT_DISTINCT=73, MIN=74, MAX=75, SUM=76, TYPEOF=77, END=78, THEN=79,
LIKE=80, IN=81, INCLUDES=82, EXCLUDES=83, ASC=84, DESC=85, NULLS=86, FIRST=87,
LAST=88, GROUP=89, ALL=90, ROWS=91, VIEW=92, HAVING=93, ROLLUP=94, TOLABEL=95,
OFFSET=96, DATA=97, CATEGORY=98, AT=99, ABOVE=100, BELOW=101, ABOVE_OR_BELOW=102,
SECURITY_ENFORCED=103, SYSTEM_MODE=104, USER_MODE=105, REFERENCE=106,
CUBE=107, FORMAT=108, TRACKING=109, VIEWSTAT=110, CUSTOM=111, STANDARD=112,
DISTANCE=113, GEOLOCATION=114, GROUPING=115, CONVERT_CURRENCY=116, CALENDAR_MONTH=117,
CALENDAR_QUARTER=118, CALENDAR_YEAR=119, DAY_IN_MONTH=120, DAY_IN_WEEK=121,
DAY_IN_YEAR=122, DAY_ONLY=123, FISCAL_MONTH=124, FISCAL_QUARTER=125, FISCAL_YEAR=126,
HOUR_IN_DAY=127, WEEK_IN_MONTH=128, WEEK_IN_YEAR=129, CONVERT_TIMEZONE=130,
YESTERDAY=131, TODAY=132, TOMORROW=133, LAST_WEEK=134, THIS_WEEK=135,
NEXT_WEEK=136, LAST_MONTH=137, THIS_MONTH=138, NEXT_MONTH=139, LAST_90_DAYS=140,
NEXT_90_DAYS=141, LAST_N_DAYS_N=142, NEXT_N_DAYS_N=143, N_DAYS_AGO_N=144,
NEXT_N_WEEKS_N=145, LAST_N_WEEKS_N=146, N_WEEKS_AGO_N=147, NEXT_N_MONTHS_N=148,
LAST_N_MONTHS_N=149, N_MONTHS_AGO_N=150, THIS_QUARTER=151, LAST_QUARTER=152,
NEXT_QUARTER=153, NEXT_N_QUARTERS_N=154, LAST_N_QUARTERS_N=155, N_QUARTERS_AGO_N=156,
THIS_YEAR=157, LAST_YEAR=158, NEXT_YEAR=159, NEXT_N_YEARS_N=160, LAST_N_YEARS_N=161,
N_YEARS_AGO_N=162, THIS_FISCAL_QUARTER=163, LAST_FISCAL_QUARTER=164, NEXT_FISCAL_QUARTER=165,
NEXT_N_FISCAL_QUARTERS_N=166, LAST_N_FISCAL_QUARTERS_N=167, N_FISCAL_QUARTERS_AGO_N=168,
THIS_FISCAL_YEAR=169, LAST_FISCAL_YEAR=170, NEXT_FISCAL_YEAR=171, NEXT_N_FISCAL_YEARS_N=172,
LAST_N_FISCAL_YEARS_N=173, N_FISCAL_YEARS_AGO_N=174, DateLiteral=175,
DateTimeLiteral=176, IntegralCurrencyLiteral=177, FIND=178, EMAIL=179,
NAME=180, PHONE=181, SIDEBAR=182, FIELDS=183, METADATA=184, PRICEBOOKID=185,
NETWORK=186, SNIPPET=187, TARGET_LENGTH=188, DIVISION=189, RETURNING=190,
LISTVIEW=191, FindLiteral=192, FindLiteralAlt=193, IntegerLiteral=194,
LongLiteral=195, NumberLiteral=196, BooleanLiteral=197, StringLiteral=198,
NullLiteral=199, LPAREN=200, RPAREN=201, LBRACE=202, RBRACE=203, LBRACK=204,
RBRACK=205, SEMI=206, COMMA=207, DOT=208, ASSIGN=209, GT=210, LT=211,
BANG=212, TILDE=213, QUESTIONDOT=214, QUESTION=215, COLON=216, EQUAL=217,
TRIPLEEQUAL=218, NOTEQUAL=219, LESSANDGREATER=220, TRIPLENOTEQUAL=221,
AND=222, OR=223, COAL=224, INC=225, DEC=226, ADD=227, SUB=228, MUL=229,
DIV=230, BITAND=231, BITOR=232, CARET=233, MAPTO=234, ADD_ASSIGN=235,
SUB_ASSIGN=236, MUL_ASSIGN=237, DIV_ASSIGN=238, AND_ASSIGN=239, OR_ASSIGN=240,
XOR_ASSIGN=241, LSHIFT_ASSIGN=242, RSHIFT_ASSIGN=243, URSHIFT_ASSIGN=244,
ATSIGN=245, Identifier=246, WS=247, DOC_COMMENT=248, COMMENT=249, LINE_COMMENT=250;
public static final int
RULE_triggerUnit = 0, RULE_triggerCase = 1, RULE_triggerBlock = 2, RULE_triggerBlockMember = 3,
RULE_compilationUnit = 4, RULE_typeDeclaration = 5, RULE_classDeclaration = 6,
RULE_enumDeclaration = 7, RULE_enumConstants = 8, RULE_interfaceDeclaration = 9,
RULE_typeList = 10, RULE_classBody = 11, RULE_interfaceBody = 12, RULE_classBodyDeclaration = 13,
RULE_modifier = 14, RULE_memberDeclaration = 15, RULE_triggerMemberDeclaration = 16,
RULE_methodDeclaration = 17, RULE_constructorDeclaration = 18, RULE_fieldDeclaration = 19,
RULE_propertyDeclaration = 20, RULE_interfaceMethodDeclaration = 21, RULE_variableDeclarators = 22,
RULE_variableDeclarator = 23, RULE_arrayInitializer = 24, RULE_typeRef = 25,
RULE_arraySubscripts = 26, RULE_typeName = 27, RULE_typeArguments = 28,
RULE_formalParameters = 29, RULE_formalParameterList = 30, RULE_formalParameter = 31,
RULE_qualifiedName = 32, RULE_literal = 33, RULE_annotation = 34, RULE_elementValuePairs = 35,
RULE_elementValuePair = 36, RULE_elementValue = 37, RULE_elementValueArrayInitializer = 38,
RULE_block = 39, RULE_localVariableDeclarationStatement = 40, RULE_localVariableDeclaration = 41,
RULE_statement = 42, RULE_ifStatement = 43, RULE_switchStatement = 44,
RULE_whenControl = 45, RULE_whenValue = 46, RULE_whenLiteral = 47, RULE_forStatement = 48,
RULE_whileStatement = 49, RULE_doWhileStatement = 50, RULE_tryStatement = 51,
RULE_returnStatement = 52, RULE_throwStatement = 53, RULE_breakStatement = 54,
RULE_continueStatement = 55, RULE_accessLevel = 56, RULE_insertStatement = 57,
RULE_updateStatement = 58, RULE_deleteStatement = 59, RULE_undeleteStatement = 60,
RULE_upsertStatement = 61, RULE_mergeStatement = 62, RULE_runAsStatement = 63,
RULE_expressionStatement = 64, RULE_propertyBlock = 65, RULE_getter = 66,
RULE_setter = 67, RULE_catchClause = 68, RULE_finallyBlock = 69, RULE_forControl = 70,
RULE_forInit = 71, RULE_enhancedForControl = 72, RULE_forUpdate = 73,
RULE_parExpression = 74, RULE_expressionList = 75, RULE_expression = 76,
RULE_primary = 77, RULE_methodCall = 78, RULE_dotMethodCall = 79, RULE_creator = 80,
RULE_createdName = 81, RULE_idCreatedNamePair = 82, RULE_noRest = 83,
RULE_classCreatorRest = 84, RULE_arrayCreatorRest = 85, RULE_mapCreatorRest = 86,
RULE_mapCreatorRestPair = 87, RULE_setCreatorRest = 88, RULE_arguments = 89,
RULE_soqlLiteral = 90, RULE_query = 91, RULE_subQuery = 92, RULE_selectList = 93,
RULE_selectEntry = 94, RULE_fieldName = 95, RULE_fromNameList = 96, RULE_subFieldList = 97,
RULE_subFieldEntry = 98, RULE_soqlFieldsParameter = 99, RULE_soqlFunction = 100,
RULE_dateFieldName = 101, RULE_locationValue = 102, RULE_coordinateValue = 103,
RULE_typeOf = 104, RULE_whenClause = 105, RULE_elseClause = 106, RULE_fieldNameList = 107,
RULE_usingScope = 108, RULE_whereClause = 109, RULE_logicalExpression = 110,
RULE_conditionalExpression = 111, RULE_fieldExpression = 112, RULE_comparisonOperator = 113,
RULE_value = 114, RULE_valueList = 115, RULE_signedNumber = 116, RULE_withClause = 117,
RULE_filteringExpression = 118, RULE_dataCategorySelection = 119, RULE_dataCategoryName = 120,
RULE_filteringSelector = 121, RULE_groupByClause = 122, RULE_orderByClause = 123,
RULE_fieldOrderList = 124, RULE_fieldOrder = 125, RULE_limitClause = 126,
RULE_offsetClause = 127, RULE_allRowsClause = 128, RULE_forClauses = 129,
RULE_boundExpression = 130, RULE_dateFormula = 131, RULE_signedInteger = 132,
RULE_soqlId = 133, RULE_soslLiteral = 134, RULE_soslLiteralAlt = 135,
RULE_soslClauses = 136, RULE_soslWithClause = 137, RULE_searchGroup = 138,
RULE_fieldSpecList = 139, RULE_fieldSpec = 140, RULE_fieldList = 141,
RULE_updateList = 142, RULE_updateType = 143, RULE_networkList = 144,
RULE_soslId = 145, RULE_id = 146, RULE_anyId = 147;
private static String[] makeRuleNames() {
return new String[] {
"triggerUnit", "triggerCase", "triggerBlock", "triggerBlockMember", "compilationUnit",
"typeDeclaration", "classDeclaration", "enumDeclaration", "enumConstants",
"interfaceDeclaration", "typeList", "classBody", "interfaceBody", "classBodyDeclaration",
"modifier", "memberDeclaration", "triggerMemberDeclaration", "methodDeclaration",
"constructorDeclaration", "fieldDeclaration", "propertyDeclaration",
"interfaceMethodDeclaration", "variableDeclarators", "variableDeclarator",
"arrayInitializer", "typeRef", "arraySubscripts", "typeName", "typeArguments",
"formalParameters", "formalParameterList", "formalParameter", "qualifiedName",
"literal", "annotation", "elementValuePairs", "elementValuePair", "elementValue",
"elementValueArrayInitializer", "block", "localVariableDeclarationStatement",
"localVariableDeclaration", "statement", "ifStatement", "switchStatement",
"whenControl", "whenValue", "whenLiteral", "forStatement", "whileStatement",
"doWhileStatement", "tryStatement", "returnStatement", "throwStatement",
"breakStatement", "continueStatement", "accessLevel", "insertStatement",
"updateStatement", "deleteStatement", "undeleteStatement", "upsertStatement",
"mergeStatement", "runAsStatement", "expressionStatement", "propertyBlock",
"getter", "setter", "catchClause", "finallyBlock", "forControl", "forInit",
"enhancedForControl", "forUpdate", "parExpression", "expressionList",
"expression", "primary", "methodCall", "dotMethodCall", "creator", "createdName",
"idCreatedNamePair", "noRest", "classCreatorRest", "arrayCreatorRest",
"mapCreatorRest", "mapCreatorRestPair", "setCreatorRest", "arguments",
"soqlLiteral", "query", "subQuery", "selectList", "selectEntry", "fieldName",
"fromNameList", "subFieldList", "subFieldEntry", "soqlFieldsParameter",
"soqlFunction", "dateFieldName", "locationValue", "coordinateValue",
"typeOf", "whenClause", "elseClause", "fieldNameList", "usingScope",
"whereClause", "logicalExpression", "conditionalExpression", "fieldExpression",
"comparisonOperator", "value", "valueList", "signedNumber", "withClause",
"filteringExpression", "dataCategorySelection", "dataCategoryName", "filteringSelector",
"groupByClause", "orderByClause", "fieldOrderList", "fieldOrder", "limitClause",
"offsetClause", "allRowsClause", "forClauses", "boundExpression", "dateFormula",
"signedInteger", "soqlId", "soslLiteral", "soslLiteralAlt", "soslClauses",
"soslWithClause", "searchGroup", "fieldSpecList", "fieldSpec", "fieldList",
"updateList", "updateType", "networkList", "soslId", "id", "anyId"
};
}
public static final String[] ruleNames = makeRuleNames();
private static String[] makeLiteralNames() {
return new String[] {
null, "'abstract'", "'after'", "'before'", "'break'", "'catch'", "'class'",
"'continue'", "'delete'", "'do'", "'else'", "'enum'", "'extends'", "'final'",
"'finally'", "'for'", "'get'", "'global'", "'if'", "'implements'", "'inherited'",
"'insert'", "'instanceof'", "'interface'", "'merge'", "'new'", "'null'",
"'on'", "'override'", "'private'", "'protected'", "'public'", "'return'",
"'system.runas'", "'set'", "'sharing'", "'static'", "'super'", "'switch'",
"'testmethod'", "'this'", "'throw'", "'transient'", "'trigger'", "'try'",
"'undelete'", "'update'", "'upsert'", "'virtual'", "'void'", "'webservice'",
"'when'", "'while'", "'with'", "'without'", "'list'", "'map'", "'system'",
"'user'", "'select'", "'count'", "'from'", "'as'", "'using'", "'scope'",
"'where'", "'order'", "'by'", "'limit'", "'and'", "'or'", "'not'", "'avg'",
"'count_distinct'", "'min'", "'max'", "'sum'", "'typeof'", "'end'", "'then'",
"'like'", "'in'", "'includes'", "'excludes'", "'asc'", "'desc'", "'nulls'",
"'first'", "'last'", "'group'", "'all'", "'rows'", "'view'", "'having'",
"'rollup'", "'tolabel'", "'offset'", "'data'", "'category'", "'at'",
"'above'", "'below'", "'above_or_below'", "'security_enforced'", "'system_mode'",
"'user_mode'", "'reference'", "'cube'", "'format'", "'tracking'", "'viewstat'",
"'custom'", "'standard'", "'distance'", "'geolocation'", "'grouping'",
"'convertcurrency'", "'calendar_month'", "'calendar_quarter'", "'calendar_year'",
"'day_in_month'", "'day_in_week'", "'day_in_year'", "'day_only'", "'fiscal_month'",
"'fiscal_quarter'", "'fiscal_year'", "'hour_in_day'", "'week_in_month'",
"'week_in_year'", "'converttimezone'", "'yesterday'", "'today'", "'tomorrow'",
"'last_week'", "'this_week'", "'next_week'", "'last_month'", "'this_month'",
"'next_month'", "'last_90_days'", "'next_90_days'", "'last_n_days'",
"'next_n_days'", "'n_days_ago'", "'next_n_weeks'", "'last_n_weeks'",
"'n_weeks_ago'", "'next_n_months'", "'last_n_months'", "'n_months_ago'",
"'this_quarter'", "'last_quarter'", "'next_quarter'", "'next_n_quarters'",
"'last_n_quarters'", "'n_quarters_ago'", "'this_year'", "'last_year'",
"'next_year'", "'next_n_years'", "'last_n_years'", "'n_years_ago'", "'this_fiscal_quarter'",
"'last_fiscal_quarter'", "'next_fiscal_quarter'", "'next_n_fiscal_quarters'",
"'last_n_fiscal_quarters'", "'n_fiscal_quarters_ago'", "'this_fiscal_year'",
"'last_fiscal_year'", "'next_fiscal_year'", "'next_n_fiscal_years'",
"'last_n_fiscal_years'", "'n_fiscal_years_ago'", null, null, null, "'find'",
"'email'", "'name'", "'phone'", "'sidebar'", "'fields'", "'metadata'",
"'pricebookid'", "'network'", "'snippet'", "'target_length'", "'division'",
"'returning'", "'listview'", null, null, null, null, null, null, null,
null, "'('", "')'", "'{'", "'}'", "'['", "']'", "';'", "','", "'.'",
"'='", "'>'", "'<'", "'!'", "'~'", "'?.'", "'?'", "':'", "'=='", "'==='",
"'!='", "'<>'", "'!=='", "'&&'", "'||'", "'??'", "'++'", "'--'", "'+'",
"'-'", "'*'", "'/'", "'&'", "'|'", "'^'", "'=>'", "'+='", "'-='", "'*='",
"'/='", "'&='", "'|='", "'^='", "'<<='", "'>>='", "'>>>='", "'@'"
};
}
private static final String[] _LITERAL_NAMES = makeLiteralNames();
private static String[] makeSymbolicNames() {
return new String[] {
null, "ABSTRACT", "AFTER", "BEFORE", "BREAK", "CATCH", "CLASS", "CONTINUE",
"DELETE", "DO", "ELSE", "ENUM", "EXTENDS", "FINAL", "FINALLY", "FOR",
"GET", "GLOBAL", "IF", "IMPLEMENTS", "INHERITED", "INSERT", "INSTANCEOF",
"INTERFACE", "MERGE", "NEW", "NULL", "ON", "OVERRIDE", "PRIVATE", "PROTECTED",
"PUBLIC", "RETURN", "SYSTEMRUNAS", "SET", "SHARING", "STATIC", "SUPER",
"SWITCH", "TESTMETHOD", "THIS", "THROW", "TRANSIENT", "TRIGGER", "TRY",
"UNDELETE", "UPDATE", "UPSERT", "VIRTUAL", "VOID", "WEBSERVICE", "WHEN",
"WHILE", "WITH", "WITHOUT", "LIST", "MAP", "SYSTEM", "USER", "SELECT",
"COUNT", "FROM", "AS", "USING", "SCOPE", "WHERE", "ORDER", "BY", "LIMIT",
"SOQLAND", "SOQLOR", "NOT", "AVG", "COUNT_DISTINCT", "MIN", "MAX", "SUM",
"TYPEOF", "END", "THEN", "LIKE", "IN", "INCLUDES", "EXCLUDES", "ASC",
"DESC", "NULLS", "FIRST", "LAST", "GROUP", "ALL", "ROWS", "VIEW", "HAVING",
"ROLLUP", "TOLABEL", "OFFSET", "DATA", "CATEGORY", "AT", "ABOVE", "BELOW",
"ABOVE_OR_BELOW", "SECURITY_ENFORCED", "SYSTEM_MODE", "USER_MODE", "REFERENCE",
"CUBE", "FORMAT", "TRACKING", "VIEWSTAT", "CUSTOM", "STANDARD", "DISTANCE",
"GEOLOCATION", "GROUPING", "CONVERT_CURRENCY", "CALENDAR_MONTH", "CALENDAR_QUARTER",
"CALENDAR_YEAR", "DAY_IN_MONTH", "DAY_IN_WEEK", "DAY_IN_YEAR", "DAY_ONLY",
"FISCAL_MONTH", "FISCAL_QUARTER", "FISCAL_YEAR", "HOUR_IN_DAY", "WEEK_IN_MONTH",
"WEEK_IN_YEAR", "CONVERT_TIMEZONE", "YESTERDAY", "TODAY", "TOMORROW",
"LAST_WEEK", "THIS_WEEK", "NEXT_WEEK", "LAST_MONTH", "THIS_MONTH", "NEXT_MONTH",
"LAST_90_DAYS", "NEXT_90_DAYS", "LAST_N_DAYS_N", "NEXT_N_DAYS_N", "N_DAYS_AGO_N",
"NEXT_N_WEEKS_N", "LAST_N_WEEKS_N", "N_WEEKS_AGO_N", "NEXT_N_MONTHS_N",
"LAST_N_MONTHS_N", "N_MONTHS_AGO_N", "THIS_QUARTER", "LAST_QUARTER",
"NEXT_QUARTER", "NEXT_N_QUARTERS_N", "LAST_N_QUARTERS_N", "N_QUARTERS_AGO_N",
"THIS_YEAR", "LAST_YEAR", "NEXT_YEAR", "NEXT_N_YEARS_N", "LAST_N_YEARS_N",
"N_YEARS_AGO_N", "THIS_FISCAL_QUARTER", "LAST_FISCAL_QUARTER", "NEXT_FISCAL_QUARTER",
"NEXT_N_FISCAL_QUARTERS_N", "LAST_N_FISCAL_QUARTERS_N", "N_FISCAL_QUARTERS_AGO_N",
"THIS_FISCAL_YEAR", "LAST_FISCAL_YEAR", "NEXT_FISCAL_YEAR", "NEXT_N_FISCAL_YEARS_N",
"LAST_N_FISCAL_YEARS_N", "N_FISCAL_YEARS_AGO_N", "DateLiteral", "DateTimeLiteral",
"IntegralCurrencyLiteral", "FIND", "EMAIL", "NAME", "PHONE", "SIDEBAR",
"FIELDS", "METADATA", "PRICEBOOKID", "NETWORK", "SNIPPET", "TARGET_LENGTH",
"DIVISION", "RETURNING", "LISTVIEW", "FindLiteral", "FindLiteralAlt",
"IntegerLiteral", "LongLiteral", "NumberLiteral", "BooleanLiteral", "StringLiteral",
"NullLiteral", "LPAREN", "RPAREN", "LBRACE", "RBRACE", "LBRACK", "RBRACK",
"SEMI", "COMMA", "DOT", "ASSIGN", "GT", "LT", "BANG", "TILDE", "QUESTIONDOT",
"QUESTION", "COLON", "EQUAL", "TRIPLEEQUAL", "NOTEQUAL", "LESSANDGREATER",
"TRIPLENOTEQUAL", "AND", "OR", "COAL", "INC", "DEC", "ADD", "SUB", "MUL",
"DIV", "BITAND", "BITOR", "CARET", "MAPTO", "ADD_ASSIGN", "SUB_ASSIGN",
"MUL_ASSIGN", "DIV_ASSIGN", "AND_ASSIGN", "OR_ASSIGN", "XOR_ASSIGN",
"LSHIFT_ASSIGN", "RSHIFT_ASSIGN", "URSHIFT_ASSIGN", "ATSIGN", "Identifier",
"WS", "DOC_COMMENT", "COMMENT", "LINE_COMMENT"
};
}
private static final String[] _SYMBOLIC_NAMES = makeSymbolicNames();
public static final Vocabulary VOCABULARY = new VocabularyImpl(_LITERAL_NAMES, _SYMBOLIC_NAMES);
/**
* @deprecated Use {@link #VOCABULARY} instead.
*/
@Deprecated
public static final String[] tokenNames;
static {
tokenNames = new String[_SYMBOLIC_NAMES.length];
for (int i = 0; i < tokenNames.length; i++) {
tokenNames[i] = VOCABULARY.getLiteralName(i);
if (tokenNames[i] == null) {
tokenNames[i] = VOCABULARY.getSymbolicName(i);
}
if (tokenNames[i] == null) {
tokenNames[i] = "";
}
}
}
@Override
@Deprecated
public String[] getTokenNames() {
return tokenNames;
}
@Override
public Vocabulary getVocabulary() {
return VOCABULARY;
}
@Override
public String getGrammarFileName() { return "ApexParser.g4"; }
@Override
public String[] getRuleNames() { return ruleNames; }
@Override
public String getSerializedATN() { return _serializedATN; }
@Override
public ATN getATN() { return _ATN; }
public void clearCache() {_interp.clearDFA();}
public ApexParser(TokenStream input) {
super(input);
_interp = new ParserATNSimulator(this,_ATN,_decisionToDFA,_sharedContextCache);
}
public static class TriggerUnitContext extends ParserRuleContext {
public TerminalNode TRIGGER() { return getToken(ApexParser.TRIGGER, 0); }
public List id() {
return getRuleContexts(IdContext.class);
}
public IdContext id(int i) {
return getRuleContext(IdContext.class,i);
}
public TerminalNode ON() { return getToken(ApexParser.ON, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public List triggerCase() {
return getRuleContexts(TriggerCaseContext.class);
}
public TriggerCaseContext triggerCase(int i) {
return getRuleContext(TriggerCaseContext.class,i);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public TriggerBlockContext triggerBlock() {
return getRuleContext(TriggerBlockContext.class,0);
}
public TerminalNode EOF() { return getToken(ApexParser.EOF, 0); }
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public TriggerUnitContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_triggerUnit; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTriggerUnit(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTriggerUnit(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTriggerUnit(this);
else return visitor.visitChildren(this);
}
}
public final TriggerUnitContext triggerUnit() throws RecognitionException {
TriggerUnitContext _localctx = new TriggerUnitContext(_ctx, getState());
enterRule(_localctx, 0, RULE_triggerUnit);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(296);
match(TRIGGER);
setState(297);
id();
setState(298);
match(ON);
setState(299);
id();
setState(300);
match(LPAREN);
setState(301);
triggerCase();
setState(306);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(302);
match(COMMA);
setState(303);
triggerCase();
}
}
setState(308);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(309);
match(RPAREN);
setState(310);
triggerBlock();
setState(311);
match(EOF);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TriggerCaseContext extends ParserRuleContext {
public TerminalNode BEFORE() { return getToken(ApexParser.BEFORE, 0); }
public TerminalNode AFTER() { return getToken(ApexParser.AFTER, 0); }
public TerminalNode INSERT() { return getToken(ApexParser.INSERT, 0); }
public TerminalNode UPDATE() { return getToken(ApexParser.UPDATE, 0); }
public TerminalNode DELETE() { return getToken(ApexParser.DELETE, 0); }
public TerminalNode UNDELETE() { return getToken(ApexParser.UNDELETE, 0); }
public TriggerCaseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_triggerCase; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTriggerCase(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTriggerCase(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTriggerCase(this);
else return visitor.visitChildren(this);
}
}
public final TriggerCaseContext triggerCase() throws RecognitionException {
TriggerCaseContext _localctx = new TriggerCaseContext(_ctx, getState());
enterRule(_localctx, 2, RULE_triggerCase);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(313);
_la = _input.LA(1);
if ( !(_la==AFTER || _la==BEFORE) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(314);
_la = _input.LA(1);
if ( !((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << DELETE) | (1L << INSERT) | (1L << UNDELETE) | (1L << UPDATE))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TriggerBlockContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List triggerBlockMember() {
return getRuleContexts(TriggerBlockMemberContext.class);
}
public TriggerBlockMemberContext triggerBlockMember(int i) {
return getRuleContext(TriggerBlockMemberContext.class,i);
}
public TriggerBlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_triggerBlock; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTriggerBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTriggerBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTriggerBlock(this);
else return visitor.visitChildren(this);
}
}
public final TriggerBlockContext triggerBlock() throws RecognitionException {
TriggerBlockContext _localctx = new TriggerBlockContext(_ctx, getState());
enterRule(_localctx, 4, RULE_triggerBlock);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(316);
match(LBRACE);
setState(320);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << BREAK) | (1L << CLASS) | (1L << CONTINUE) | (1L << DELETE) | (1L << DO) | (1L << ENUM) | (1L << FINAL) | (1L << FOR) | (1L << GET) | (1L << GLOBAL) | (1L << IF) | (1L << INHERITED) | (1L << INSERT) | (1L << INSTANCEOF) | (1L << INTERFACE) | (1L << MERGE) | (1L << NEW) | (1L << NULL) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << RETURN) | (1L << SYSTEMRUNAS) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SUPER) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << THIS) | (1L << THROW) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << TRY) | (1L << UNDELETE) | (1L << UPDATE) | (1L << UPSERT) | (1L << VIRTUAL) | (1L << VOID) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WHILE) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACE - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (ATSIGN - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
{
setState(317);
triggerBlockMember();
}
}
setState(322);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(323);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TriggerBlockMemberContext extends ParserRuleContext {
public TriggerMemberDeclarationContext triggerMemberDeclaration() {
return getRuleContext(TriggerMemberDeclarationContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public TriggerBlockMemberContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_triggerBlockMember; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTriggerBlockMember(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTriggerBlockMember(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTriggerBlockMember(this);
else return visitor.visitChildren(this);
}
}
public final TriggerBlockMemberContext triggerBlockMember() throws RecognitionException {
TriggerBlockMemberContext _localctx = new TriggerBlockMemberContext(_ctx, getState());
enterRule(_localctx, 6, RULE_triggerBlockMember);
try {
int _alt;
setState(333);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,3,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(328);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,2,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(325);
modifier();
}
}
}
setState(330);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,2,_ctx);
}
setState(331);
triggerMemberDeclaration();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(332);
statement();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CompilationUnitContext extends ParserRuleContext {
public TypeDeclarationContext typeDeclaration() {
return getRuleContext(TypeDeclarationContext.class,0);
}
public TerminalNode EOF() { return getToken(ApexParser.EOF, 0); }
public CompilationUnitContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_compilationUnit; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCompilationUnit(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCompilationUnit(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCompilationUnit(this);
else return visitor.visitChildren(this);
}
}
public final CompilationUnitContext compilationUnit() throws RecognitionException {
CompilationUnitContext _localctx = new CompilationUnitContext(_ctx, getState());
enterRule(_localctx, 8, RULE_compilationUnit);
try {
enterOuterAlt(_localctx, 1);
{
setState(335);
typeDeclaration();
setState(336);
match(EOF);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeDeclarationContext extends ParserRuleContext {
public ClassDeclarationContext classDeclaration() {
return getRuleContext(ClassDeclarationContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public EnumDeclarationContext enumDeclaration() {
return getRuleContext(EnumDeclarationContext.class,0);
}
public InterfaceDeclarationContext interfaceDeclaration() {
return getRuleContext(InterfaceDeclarationContext.class,0);
}
public TypeDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final TypeDeclarationContext typeDeclaration() throws RecognitionException {
TypeDeclarationContext _localctx = new TypeDeclarationContext(_ctx, getState());
enterRule(_localctx, 10, RULE_typeDeclaration);
int _la;
try {
setState(359);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,7,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(341);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << FINAL) | (1L << GLOBAL) | (1L << INHERITED) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << STATIC) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WITH) | (1L << WITHOUT))) != 0) || _la==ATSIGN) {
{
{
setState(338);
modifier();
}
}
setState(343);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(344);
classDeclaration();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(348);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << FINAL) | (1L << GLOBAL) | (1L << INHERITED) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << STATIC) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WITH) | (1L << WITHOUT))) != 0) || _la==ATSIGN) {
{
{
setState(345);
modifier();
}
}
setState(350);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(351);
enumDeclaration();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(355);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << FINAL) | (1L << GLOBAL) | (1L << INHERITED) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << STATIC) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WITH) | (1L << WITHOUT))) != 0) || _la==ATSIGN) {
{
{
setState(352);
modifier();
}
}
setState(357);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(358);
interfaceDeclaration();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ClassDeclarationContext extends ParserRuleContext {
public TerminalNode CLASS() { return getToken(ApexParser.CLASS, 0); }
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public ClassBodyContext classBody() {
return getRuleContext(ClassBodyContext.class,0);
}
public TerminalNode EXTENDS() { return getToken(ApexParser.EXTENDS, 0); }
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public TerminalNode IMPLEMENTS() { return getToken(ApexParser.IMPLEMENTS, 0); }
public TypeListContext typeList() {
return getRuleContext(TypeListContext.class,0);
}
public ClassDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_classDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterClassDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitClassDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitClassDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final ClassDeclarationContext classDeclaration() throws RecognitionException {
ClassDeclarationContext _localctx = new ClassDeclarationContext(_ctx, getState());
enterRule(_localctx, 12, RULE_classDeclaration);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(361);
match(CLASS);
setState(362);
id();
setState(365);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==EXTENDS) {
{
setState(363);
match(EXTENDS);
setState(364);
typeRef();
}
}
setState(369);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==IMPLEMENTS) {
{
setState(367);
match(IMPLEMENTS);
setState(368);
typeList();
}
}
setState(371);
classBody();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class EnumDeclarationContext extends ParserRuleContext {
public TerminalNode ENUM() { return getToken(ApexParser.ENUM, 0); }
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public EnumConstantsContext enumConstants() {
return getRuleContext(EnumConstantsContext.class,0);
}
public EnumDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_enumDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterEnumDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitEnumDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitEnumDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final EnumDeclarationContext enumDeclaration() throws RecognitionException {
EnumDeclarationContext _localctx = new EnumDeclarationContext(_ctx, getState());
enterRule(_localctx, 14, RULE_enumDeclaration);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(373);
match(ENUM);
setState(374);
id();
setState(375);
match(LBRACE);
setState(377);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << SET) | (1L << SHARING) | (1L << SWITCH) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || _la==Identifier) {
{
setState(376);
enumConstants();
}
}
setState(379);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class EnumConstantsContext extends ParserRuleContext {
public List id() {
return getRuleContexts(IdContext.class);
}
public IdContext id(int i) {
return getRuleContext(IdContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public EnumConstantsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_enumConstants; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterEnumConstants(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitEnumConstants(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitEnumConstants(this);
else return visitor.visitChildren(this);
}
}
public final EnumConstantsContext enumConstants() throws RecognitionException {
EnumConstantsContext _localctx = new EnumConstantsContext(_ctx, getState());
enterRule(_localctx, 16, RULE_enumConstants);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(381);
id();
setState(386);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(382);
match(COMMA);
setState(383);
id();
}
}
setState(388);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class InterfaceDeclarationContext extends ParserRuleContext {
public TerminalNode INTERFACE() { return getToken(ApexParser.INTERFACE, 0); }
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public InterfaceBodyContext interfaceBody() {
return getRuleContext(InterfaceBodyContext.class,0);
}
public TerminalNode EXTENDS() { return getToken(ApexParser.EXTENDS, 0); }
public TypeListContext typeList() {
return getRuleContext(TypeListContext.class,0);
}
public InterfaceDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_interfaceDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterInterfaceDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitInterfaceDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitInterfaceDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final InterfaceDeclarationContext interfaceDeclaration() throws RecognitionException {
InterfaceDeclarationContext _localctx = new InterfaceDeclarationContext(_ctx, getState());
enterRule(_localctx, 18, RULE_interfaceDeclaration);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(389);
match(INTERFACE);
setState(390);
id();
setState(393);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==EXTENDS) {
{
setState(391);
match(EXTENDS);
setState(392);
typeList();
}
}
setState(395);
interfaceBody();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeListContext extends ParserRuleContext {
public List typeRef() {
return getRuleContexts(TypeRefContext.class);
}
public TypeRefContext typeRef(int i) {
return getRuleContext(TypeRefContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public TypeListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeList(this);
else return visitor.visitChildren(this);
}
}
public final TypeListContext typeList() throws RecognitionException {
TypeListContext _localctx = new TypeListContext(_ctx, getState());
enterRule(_localctx, 20, RULE_typeList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(397);
typeRef();
setState(402);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(398);
match(COMMA);
setState(399);
typeRef();
}
}
setState(404);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ClassBodyContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List classBodyDeclaration() {
return getRuleContexts(ClassBodyDeclarationContext.class);
}
public ClassBodyDeclarationContext classBodyDeclaration(int i) {
return getRuleContext(ClassBodyDeclarationContext.class,i);
}
public ClassBodyContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_classBody; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterClassBody(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitClassBody(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitClassBody(this);
else return visitor.visitChildren(this);
}
}
public final ClassBodyContext classBody() throws RecognitionException {
ClassBodyContext _localctx = new ClassBodyContext(_ctx, getState());
enterRule(_localctx, 22, RULE_classBody);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(405);
match(LBRACE);
setState(409);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << CLASS) | (1L << ENUM) | (1L << FINAL) | (1L << GET) | (1L << GLOBAL) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << INTERFACE) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VIRTUAL) | (1L << VOID) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 202)) & ~0x3f) == 0 && ((1L << (_la - 202)) & ((1L << (LBRACE - 202)) | (1L << (SEMI - 202)) | (1L << (ATSIGN - 202)) | (1L << (Identifier - 202)))) != 0)) {
{
{
setState(406);
classBodyDeclaration();
}
}
setState(411);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(412);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class InterfaceBodyContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List interfaceMethodDeclaration() {
return getRuleContexts(InterfaceMethodDeclarationContext.class);
}
public InterfaceMethodDeclarationContext interfaceMethodDeclaration(int i) {
return getRuleContext(InterfaceMethodDeclarationContext.class,i);
}
public InterfaceBodyContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_interfaceBody; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterInterfaceBody(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitInterfaceBody(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitInterfaceBody(this);
else return visitor.visitChildren(this);
}
}
public final InterfaceBodyContext interfaceBody() throws RecognitionException {
InterfaceBodyContext _localctx = new InterfaceBodyContext(_ctx, getState());
enterRule(_localctx, 24, RULE_interfaceBody);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(414);
match(LBRACE);
setState(418);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << FINAL) | (1L << GET) | (1L << GLOBAL) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VIRTUAL) | (1L << VOID) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || _la==ATSIGN || _la==Identifier) {
{
{
setState(415);
interfaceMethodDeclaration();
}
}
setState(420);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(421);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ClassBodyDeclarationContext extends ParserRuleContext {
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public TerminalNode STATIC() { return getToken(ApexParser.STATIC, 0); }
public MemberDeclarationContext memberDeclaration() {
return getRuleContext(MemberDeclarationContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public ClassBodyDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_classBodyDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterClassBodyDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitClassBodyDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitClassBodyDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final ClassBodyDeclarationContext classBodyDeclaration() throws RecognitionException {
ClassBodyDeclarationContext _localctx = new ClassBodyDeclarationContext(_ctx, getState());
enterRule(_localctx, 26, RULE_classBodyDeclaration);
int _la;
try {
int _alt;
setState(435);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,18,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(423);
match(SEMI);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(425);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==STATIC) {
{
setState(424);
match(STATIC);
}
}
setState(427);
block();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(431);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,17,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(428);
modifier();
}
}
}
setState(433);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,17,_ctx);
}
setState(434);
memberDeclaration();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ModifierContext extends ParserRuleContext {
public AnnotationContext annotation() {
return getRuleContext(AnnotationContext.class,0);
}
public TerminalNode GLOBAL() { return getToken(ApexParser.GLOBAL, 0); }
public TerminalNode PUBLIC() { return getToken(ApexParser.PUBLIC, 0); }
public TerminalNode PROTECTED() { return getToken(ApexParser.PROTECTED, 0); }
public TerminalNode PRIVATE() { return getToken(ApexParser.PRIVATE, 0); }
public TerminalNode TRANSIENT() { return getToken(ApexParser.TRANSIENT, 0); }
public TerminalNode STATIC() { return getToken(ApexParser.STATIC, 0); }
public TerminalNode ABSTRACT() { return getToken(ApexParser.ABSTRACT, 0); }
public TerminalNode FINAL() { return getToken(ApexParser.FINAL, 0); }
public TerminalNode WEBSERVICE() { return getToken(ApexParser.WEBSERVICE, 0); }
public TerminalNode OVERRIDE() { return getToken(ApexParser.OVERRIDE, 0); }
public TerminalNode VIRTUAL() { return getToken(ApexParser.VIRTUAL, 0); }
public TerminalNode TESTMETHOD() { return getToken(ApexParser.TESTMETHOD, 0); }
public TerminalNode WITH() { return getToken(ApexParser.WITH, 0); }
public TerminalNode SHARING() { return getToken(ApexParser.SHARING, 0); }
public TerminalNode WITHOUT() { return getToken(ApexParser.WITHOUT, 0); }
public TerminalNode INHERITED() { return getToken(ApexParser.INHERITED, 0); }
public ModifierContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_modifier; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterModifier(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitModifier(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitModifier(this);
else return visitor.visitChildren(this);
}
}
public final ModifierContext modifier() throws RecognitionException {
ModifierContext _localctx = new ModifierContext(_ctx, getState());
enterRule(_localctx, 28, RULE_modifier);
try {
setState(456);
_errHandler.sync(this);
switch (_input.LA(1)) {
case ATSIGN:
enterOuterAlt(_localctx, 1);
{
setState(437);
annotation();
}
break;
case GLOBAL:
enterOuterAlt(_localctx, 2);
{
setState(438);
match(GLOBAL);
}
break;
case PUBLIC:
enterOuterAlt(_localctx, 3);
{
setState(439);
match(PUBLIC);
}
break;
case PROTECTED:
enterOuterAlt(_localctx, 4);
{
setState(440);
match(PROTECTED);
}
break;
case PRIVATE:
enterOuterAlt(_localctx, 5);
{
setState(441);
match(PRIVATE);
}
break;
case TRANSIENT:
enterOuterAlt(_localctx, 6);
{
setState(442);
match(TRANSIENT);
}
break;
case STATIC:
enterOuterAlt(_localctx, 7);
{
setState(443);
match(STATIC);
}
break;
case ABSTRACT:
enterOuterAlt(_localctx, 8);
{
setState(444);
match(ABSTRACT);
}
break;
case FINAL:
enterOuterAlt(_localctx, 9);
{
setState(445);
match(FINAL);
}
break;
case WEBSERVICE:
enterOuterAlt(_localctx, 10);
{
setState(446);
match(WEBSERVICE);
}
break;
case OVERRIDE:
enterOuterAlt(_localctx, 11);
{
setState(447);
match(OVERRIDE);
}
break;
case VIRTUAL:
enterOuterAlt(_localctx, 12);
{
setState(448);
match(VIRTUAL);
}
break;
case TESTMETHOD:
enterOuterAlt(_localctx, 13);
{
setState(449);
match(TESTMETHOD);
}
break;
case WITH:
enterOuterAlt(_localctx, 14);
{
setState(450);
match(WITH);
setState(451);
match(SHARING);
}
break;
case WITHOUT:
enterOuterAlt(_localctx, 15);
{
setState(452);
match(WITHOUT);
setState(453);
match(SHARING);
}
break;
case INHERITED:
enterOuterAlt(_localctx, 16);
{
setState(454);
match(INHERITED);
setState(455);
match(SHARING);
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MemberDeclarationContext extends ParserRuleContext {
public MethodDeclarationContext methodDeclaration() {
return getRuleContext(MethodDeclarationContext.class,0);
}
public FieldDeclarationContext fieldDeclaration() {
return getRuleContext(FieldDeclarationContext.class,0);
}
public ConstructorDeclarationContext constructorDeclaration() {
return getRuleContext(ConstructorDeclarationContext.class,0);
}
public InterfaceDeclarationContext interfaceDeclaration() {
return getRuleContext(InterfaceDeclarationContext.class,0);
}
public ClassDeclarationContext classDeclaration() {
return getRuleContext(ClassDeclarationContext.class,0);
}
public EnumDeclarationContext enumDeclaration() {
return getRuleContext(EnumDeclarationContext.class,0);
}
public PropertyDeclarationContext propertyDeclaration() {
return getRuleContext(PropertyDeclarationContext.class,0);
}
public MemberDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_memberDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMemberDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMemberDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMemberDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final MemberDeclarationContext memberDeclaration() throws RecognitionException {
MemberDeclarationContext _localctx = new MemberDeclarationContext(_ctx, getState());
enterRule(_localctx, 30, RULE_memberDeclaration);
try {
setState(465);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,20,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(458);
methodDeclaration();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(459);
fieldDeclaration();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(460);
constructorDeclaration();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(461);
interfaceDeclaration();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(462);
classDeclaration();
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(463);
enumDeclaration();
}
break;
case 7:
enterOuterAlt(_localctx, 7);
{
setState(464);
propertyDeclaration();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TriggerMemberDeclarationContext extends ParserRuleContext {
public MethodDeclarationContext methodDeclaration() {
return getRuleContext(MethodDeclarationContext.class,0);
}
public FieldDeclarationContext fieldDeclaration() {
return getRuleContext(FieldDeclarationContext.class,0);
}
public InterfaceDeclarationContext interfaceDeclaration() {
return getRuleContext(InterfaceDeclarationContext.class,0);
}
public ClassDeclarationContext classDeclaration() {
return getRuleContext(ClassDeclarationContext.class,0);
}
public EnumDeclarationContext enumDeclaration() {
return getRuleContext(EnumDeclarationContext.class,0);
}
public PropertyDeclarationContext propertyDeclaration() {
return getRuleContext(PropertyDeclarationContext.class,0);
}
public TriggerMemberDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_triggerMemberDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTriggerMemberDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTriggerMemberDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTriggerMemberDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final TriggerMemberDeclarationContext triggerMemberDeclaration() throws RecognitionException {
TriggerMemberDeclarationContext _localctx = new TriggerMemberDeclarationContext(_ctx, getState());
enterRule(_localctx, 32, RULE_triggerMemberDeclaration);
try {
setState(473);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,21,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(467);
methodDeclaration();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(468);
fieldDeclaration();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(469);
interfaceDeclaration();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(470);
classDeclaration();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(471);
enumDeclaration();
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(472);
propertyDeclaration();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MethodDeclarationContext extends ParserRuleContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public FormalParametersContext formalParameters() {
return getRuleContext(FormalParametersContext.class,0);
}
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public TerminalNode VOID() { return getToken(ApexParser.VOID, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public MethodDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMethodDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMethodDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMethodDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final MethodDeclarationContext methodDeclaration() throws RecognitionException {
MethodDeclarationContext _localctx = new MethodDeclarationContext(_ctx, getState());
enterRule(_localctx, 34, RULE_methodDeclaration);
try {
enterOuterAlt(_localctx, 1);
{
setState(477);
_errHandler.sync(this);
switch (_input.LA(1)) {
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case SET:
case SHARING:
case SWITCH:
case TRANSIENT:
case TRIGGER:
case WHEN:
case WITH:
case WITHOUT:
case LIST:
case MAP:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case Identifier:
{
setState(475);
typeRef();
}
break;
case VOID:
{
setState(476);
match(VOID);
}
break;
default:
throw new NoViableAltException(this);
}
setState(479);
id();
setState(480);
formalParameters();
setState(483);
_errHandler.sync(this);
switch (_input.LA(1)) {
case LBRACE:
{
setState(481);
block();
}
break;
case SEMI:
{
setState(482);
match(SEMI);
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ConstructorDeclarationContext extends ParserRuleContext {
public QualifiedNameContext qualifiedName() {
return getRuleContext(QualifiedNameContext.class,0);
}
public FormalParametersContext formalParameters() {
return getRuleContext(FormalParametersContext.class,0);
}
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public ConstructorDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_constructorDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterConstructorDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitConstructorDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitConstructorDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final ConstructorDeclarationContext constructorDeclaration() throws RecognitionException {
ConstructorDeclarationContext _localctx = new ConstructorDeclarationContext(_ctx, getState());
enterRule(_localctx, 36, RULE_constructorDeclaration);
try {
enterOuterAlt(_localctx, 1);
{
setState(485);
qualifiedName();
setState(486);
formalParameters();
setState(487);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FieldDeclarationContext extends ParserRuleContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public VariableDeclaratorsContext variableDeclarators() {
return getRuleContext(VariableDeclaratorsContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public FieldDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fieldDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFieldDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFieldDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFieldDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final FieldDeclarationContext fieldDeclaration() throws RecognitionException {
FieldDeclarationContext _localctx = new FieldDeclarationContext(_ctx, getState());
enterRule(_localctx, 38, RULE_fieldDeclaration);
try {
enterOuterAlt(_localctx, 1);
{
setState(489);
typeRef();
setState(490);
variableDeclarators();
setState(491);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PropertyDeclarationContext extends ParserRuleContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List propertyBlock() {
return getRuleContexts(PropertyBlockContext.class);
}
public PropertyBlockContext propertyBlock(int i) {
return getRuleContext(PropertyBlockContext.class,i);
}
public PropertyDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_propertyDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterPropertyDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitPropertyDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitPropertyDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final PropertyDeclarationContext propertyDeclaration() throws RecognitionException {
PropertyDeclarationContext _localctx = new PropertyDeclarationContext(_ctx, getState());
enterRule(_localctx, 40, RULE_propertyDeclaration);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(493);
typeRef();
setState(494);
id();
setState(495);
match(LBRACE);
setState(499);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << FINAL) | (1L << GET) | (1L << GLOBAL) | (1L << INHERITED) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << SET) | (1L << STATIC) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WITH) | (1L << WITHOUT))) != 0) || _la==ATSIGN) {
{
{
setState(496);
propertyBlock();
}
}
setState(501);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(502);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class InterfaceMethodDeclarationContext extends ParserRuleContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public FormalParametersContext formalParameters() {
return getRuleContext(FormalParametersContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public TerminalNode VOID() { return getToken(ApexParser.VOID, 0); }
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public InterfaceMethodDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_interfaceMethodDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterInterfaceMethodDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitInterfaceMethodDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitInterfaceMethodDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final InterfaceMethodDeclarationContext interfaceMethodDeclaration() throws RecognitionException {
InterfaceMethodDeclarationContext _localctx = new InterfaceMethodDeclarationContext(_ctx, getState());
enterRule(_localctx, 42, RULE_interfaceMethodDeclaration);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(507);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,25,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(504);
modifier();
}
}
}
setState(509);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,25,_ctx);
}
setState(512);
_errHandler.sync(this);
switch (_input.LA(1)) {
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case SET:
case SHARING:
case SWITCH:
case TRANSIENT:
case TRIGGER:
case WHEN:
case WITH:
case WITHOUT:
case LIST:
case MAP:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case Identifier:
{
setState(510);
typeRef();
}
break;
case VOID:
{
setState(511);
match(VOID);
}
break;
default:
throw new NoViableAltException(this);
}
setState(514);
id();
setState(515);
formalParameters();
setState(516);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class VariableDeclaratorsContext extends ParserRuleContext {
public List variableDeclarator() {
return getRuleContexts(VariableDeclaratorContext.class);
}
public VariableDeclaratorContext variableDeclarator(int i) {
return getRuleContext(VariableDeclaratorContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public VariableDeclaratorsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_variableDeclarators; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterVariableDeclarators(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitVariableDeclarators(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitVariableDeclarators(this);
else return visitor.visitChildren(this);
}
}
public final VariableDeclaratorsContext variableDeclarators() throws RecognitionException {
VariableDeclaratorsContext _localctx = new VariableDeclaratorsContext(_ctx, getState());
enterRule(_localctx, 44, RULE_variableDeclarators);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(518);
variableDeclarator();
setState(523);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(519);
match(COMMA);
setState(520);
variableDeclarator();
}
}
setState(525);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class VariableDeclaratorContext extends ParserRuleContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode ASSIGN() { return getToken(ApexParser.ASSIGN, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public VariableDeclaratorContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_variableDeclarator; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterVariableDeclarator(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitVariableDeclarator(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitVariableDeclarator(this);
else return visitor.visitChildren(this);
}
}
public final VariableDeclaratorContext variableDeclarator() throws RecognitionException {
VariableDeclaratorContext _localctx = new VariableDeclaratorContext(_ctx, getState());
enterRule(_localctx, 46, RULE_variableDeclarator);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(526);
id();
setState(529);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ASSIGN) {
{
setState(527);
match(ASSIGN);
setState(528);
expression(0);
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArrayInitializerContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public ArrayInitializerContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_arrayInitializer; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArrayInitializer(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArrayInitializer(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArrayInitializer(this);
else return visitor.visitChildren(this);
}
}
public final ArrayInitializerContext arrayInitializer() throws RecognitionException {
ArrayInitializerContext _localctx = new ArrayInitializerContext(_ctx, getState());
enterRule(_localctx, 48, RULE_arrayInitializer);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(531);
match(LBRACE);
setState(543);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(532);
expression(0);
setState(537);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,29,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(533);
match(COMMA);
setState(534);
expression(0);
}
}
}
setState(539);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,29,_ctx);
}
setState(541);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(540);
match(COMMA);
}
}
}
}
setState(545);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeRefContext extends ParserRuleContext {
public List typeName() {
return getRuleContexts(TypeNameContext.class);
}
public TypeNameContext typeName(int i) {
return getRuleContext(TypeNameContext.class,i);
}
public ArraySubscriptsContext arraySubscripts() {
return getRuleContext(ArraySubscriptsContext.class,0);
}
public List DOT() { return getTokens(ApexParser.DOT); }
public TerminalNode DOT(int i) {
return getToken(ApexParser.DOT, i);
}
public TypeRefContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeRef; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeRef(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeRef(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeRef(this);
else return visitor.visitChildren(this);
}
}
public final TypeRefContext typeRef() throws RecognitionException {
TypeRefContext _localctx = new TypeRefContext(_ctx, getState());
enterRule(_localctx, 50, RULE_typeRef);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(547);
typeName();
setState(552);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,32,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(548);
match(DOT);
setState(549);
typeName();
}
}
}
setState(554);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,32,_ctx);
}
setState(555);
arraySubscripts();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArraySubscriptsContext extends ParserRuleContext {
public List LBRACK() { return getTokens(ApexParser.LBRACK); }
public TerminalNode LBRACK(int i) {
return getToken(ApexParser.LBRACK, i);
}
public List RBRACK() { return getTokens(ApexParser.RBRACK); }
public TerminalNode RBRACK(int i) {
return getToken(ApexParser.RBRACK, i);
}
public ArraySubscriptsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_arraySubscripts; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArraySubscripts(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArraySubscripts(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArraySubscripts(this);
else return visitor.visitChildren(this);
}
}
public final ArraySubscriptsContext arraySubscripts() throws RecognitionException {
ArraySubscriptsContext _localctx = new ArraySubscriptsContext(_ctx, getState());
enterRule(_localctx, 52, RULE_arraySubscripts);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(561);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,33,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(557);
match(LBRACK);
setState(558);
match(RBRACK);
}
}
}
setState(563);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,33,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeNameContext extends ParserRuleContext {
public TerminalNode LIST() { return getToken(ApexParser.LIST, 0); }
public TypeArgumentsContext typeArguments() {
return getRuleContext(TypeArgumentsContext.class,0);
}
public TerminalNode SET() { return getToken(ApexParser.SET, 0); }
public TerminalNode MAP() { return getToken(ApexParser.MAP, 0); }
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TypeNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeName(this);
else return visitor.visitChildren(this);
}
}
public final TypeNameContext typeName() throws RecognitionException {
TypeNameContext _localctx = new TypeNameContext(_ctx, getState());
enterRule(_localctx, 54, RULE_typeName);
try {
setState(580);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,38,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(564);
match(LIST);
setState(566);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,34,_ctx) ) {
case 1:
{
setState(565);
typeArguments();
}
break;
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(568);
match(SET);
setState(570);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,35,_ctx) ) {
case 1:
{
setState(569);
typeArguments();
}
break;
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(572);
match(MAP);
setState(574);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,36,_ctx) ) {
case 1:
{
setState(573);
typeArguments();
}
break;
}
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(576);
id();
setState(578);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,37,_ctx) ) {
case 1:
{
setState(577);
typeArguments();
}
break;
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeArgumentsContext extends ParserRuleContext {
public TerminalNode LT() { return getToken(ApexParser.LT, 0); }
public TypeListContext typeList() {
return getRuleContext(TypeListContext.class,0);
}
public TerminalNode GT() { return getToken(ApexParser.GT, 0); }
public TypeArgumentsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeArguments; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeArguments(this);
else return visitor.visitChildren(this);
}
}
public final TypeArgumentsContext typeArguments() throws RecognitionException {
TypeArgumentsContext _localctx = new TypeArgumentsContext(_ctx, getState());
enterRule(_localctx, 56, RULE_typeArguments);
try {
enterOuterAlt(_localctx, 1);
{
setState(582);
match(LT);
setState(583);
typeList();
setState(584);
match(GT);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FormalParametersContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public FormalParameterListContext formalParameterList() {
return getRuleContext(FormalParameterListContext.class,0);
}
public FormalParametersContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_formalParameters; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFormalParameters(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFormalParameters(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFormalParameters(this);
else return visitor.visitChildren(this);
}
}
public final FormalParametersContext formalParameters() throws RecognitionException {
FormalParametersContext _localctx = new FormalParametersContext(_ctx, getState());
enterRule(_localctx, 58, RULE_formalParameters);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(586);
match(LPAREN);
setState(588);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << FINAL) | (1L << GET) | (1L << GLOBAL) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || _la==ATSIGN || _la==Identifier) {
{
setState(587);
formalParameterList();
}
}
setState(590);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FormalParameterListContext extends ParserRuleContext {
public List formalParameter() {
return getRuleContexts(FormalParameterContext.class);
}
public FormalParameterContext formalParameter(int i) {
return getRuleContext(FormalParameterContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public FormalParameterListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_formalParameterList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFormalParameterList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFormalParameterList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFormalParameterList(this);
else return visitor.visitChildren(this);
}
}
public final FormalParameterListContext formalParameterList() throws RecognitionException {
FormalParameterListContext _localctx = new FormalParameterListContext(_ctx, getState());
enterRule(_localctx, 60, RULE_formalParameterList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(592);
formalParameter();
setState(597);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(593);
match(COMMA);
setState(594);
formalParameter();
}
}
setState(599);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FormalParameterContext extends ParserRuleContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public FormalParameterContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_formalParameter; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFormalParameter(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFormalParameter(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFormalParameter(this);
else return visitor.visitChildren(this);
}
}
public final FormalParameterContext formalParameter() throws RecognitionException {
FormalParameterContext _localctx = new FormalParameterContext(_ctx, getState());
enterRule(_localctx, 62, RULE_formalParameter);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(603);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,41,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(600);
modifier();
}
}
}
setState(605);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,41,_ctx);
}
setState(606);
typeRef();
setState(607);
id();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class QualifiedNameContext extends ParserRuleContext {
public List id() {
return getRuleContexts(IdContext.class);
}
public IdContext id(int i) {
return getRuleContext(IdContext.class,i);
}
public List DOT() { return getTokens(ApexParser.DOT); }
public TerminalNode DOT(int i) {
return getToken(ApexParser.DOT, i);
}
public QualifiedNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_qualifiedName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterQualifiedName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitQualifiedName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitQualifiedName(this);
else return visitor.visitChildren(this);
}
}
public final QualifiedNameContext qualifiedName() throws RecognitionException {
QualifiedNameContext _localctx = new QualifiedNameContext(_ctx, getState());
enterRule(_localctx, 64, RULE_qualifiedName);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(609);
id();
setState(614);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==DOT) {
{
{
setState(610);
match(DOT);
setState(611);
id();
}
}
setState(616);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LiteralContext extends ParserRuleContext {
public TerminalNode IntegerLiteral() { return getToken(ApexParser.IntegerLiteral, 0); }
public TerminalNode LongLiteral() { return getToken(ApexParser.LongLiteral, 0); }
public TerminalNode NumberLiteral() { return getToken(ApexParser.NumberLiteral, 0); }
public TerminalNode StringLiteral() { return getToken(ApexParser.StringLiteral, 0); }
public TerminalNode BooleanLiteral() { return getToken(ApexParser.BooleanLiteral, 0); }
public TerminalNode NULL() { return getToken(ApexParser.NULL, 0); }
public LiteralContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_literal; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLiteral(this);
else return visitor.visitChildren(this);
}
}
public final LiteralContext literal() throws RecognitionException {
LiteralContext _localctx = new LiteralContext(_ctx, getState());
enterRule(_localctx, 66, RULE_literal);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(617);
_la = _input.LA(1);
if ( !(_la==NULL || ((((_la - 194)) & ~0x3f) == 0 && ((1L << (_la - 194)) & ((1L << (IntegerLiteral - 194)) | (1L << (LongLiteral - 194)) | (1L << (NumberLiteral - 194)) | (1L << (BooleanLiteral - 194)) | (1L << (StringLiteral - 194)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class AnnotationContext extends ParserRuleContext {
public TerminalNode ATSIGN() { return getToken(ApexParser.ATSIGN, 0); }
public QualifiedNameContext qualifiedName() {
return getRuleContext(QualifiedNameContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ElementValuePairsContext elementValuePairs() {
return getRuleContext(ElementValuePairsContext.class,0);
}
public ElementValueContext elementValue() {
return getRuleContext(ElementValueContext.class,0);
}
public AnnotationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_annotation; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterAnnotation(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitAnnotation(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitAnnotation(this);
else return visitor.visitChildren(this);
}
}
public final AnnotationContext annotation() throws RecognitionException {
AnnotationContext _localctx = new AnnotationContext(_ctx, getState());
enterRule(_localctx, 68, RULE_annotation);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(619);
match(ATSIGN);
setState(620);
qualifiedName();
setState(627);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==LPAREN) {
{
setState(621);
match(LPAREN);
setState(624);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,43,_ctx) ) {
case 1:
{
setState(622);
elementValuePairs();
}
break;
case 2:
{
setState(623);
elementValue();
}
break;
}
setState(626);
match(RPAREN);
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ElementValuePairsContext extends ParserRuleContext {
public List elementValuePair() {
return getRuleContexts(ElementValuePairContext.class);
}
public ElementValuePairContext elementValuePair(int i) {
return getRuleContext(ElementValuePairContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public ElementValuePairsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elementValuePairs; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterElementValuePairs(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitElementValuePairs(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitElementValuePairs(this);
else return visitor.visitChildren(this);
}
}
public final ElementValuePairsContext elementValuePairs() throws RecognitionException {
ElementValuePairsContext _localctx = new ElementValuePairsContext(_ctx, getState());
enterRule(_localctx, 70, RULE_elementValuePairs);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(629);
elementValuePair();
setState(636);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << SET) | (1L << SHARING) | (1L << SWITCH) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || _la==COMMA || _la==Identifier) {
{
{
setState(631);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(630);
match(COMMA);
}
}
setState(633);
elementValuePair();
}
}
setState(638);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ElementValuePairContext extends ParserRuleContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode ASSIGN() { return getToken(ApexParser.ASSIGN, 0); }
public ElementValueContext elementValue() {
return getRuleContext(ElementValueContext.class,0);
}
public ElementValuePairContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elementValuePair; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterElementValuePair(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitElementValuePair(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitElementValuePair(this);
else return visitor.visitChildren(this);
}
}
public final ElementValuePairContext elementValuePair() throws RecognitionException {
ElementValuePairContext _localctx = new ElementValuePairContext(_ctx, getState());
enterRule(_localctx, 72, RULE_elementValuePair);
try {
enterOuterAlt(_localctx, 1);
{
setState(639);
id();
setState(640);
match(ASSIGN);
setState(641);
elementValue();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ElementValueContext extends ParserRuleContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public AnnotationContext annotation() {
return getRuleContext(AnnotationContext.class,0);
}
public ElementValueArrayInitializerContext elementValueArrayInitializer() {
return getRuleContext(ElementValueArrayInitializerContext.class,0);
}
public ElementValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elementValue; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterElementValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitElementValue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitElementValue(this);
else return visitor.visitChildren(this);
}
}
public final ElementValueContext elementValue() throws RecognitionException {
ElementValueContext _localctx = new ElementValueContext(_ctx, getState());
enterRule(_localctx, 74, RULE_elementValue);
try {
setState(646);
_errHandler.sync(this);
switch (_input.LA(1)) {
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case NEW:
case NULL:
case SET:
case SHARING:
case SUPER:
case SWITCH:
case THIS:
case TRANSIENT:
case TRIGGER:
case VOID:
case WHEN:
case WITH:
case WITHOUT:
case LIST:
case MAP:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case FindLiteral:
case IntegerLiteral:
case LongLiteral:
case NumberLiteral:
case BooleanLiteral:
case StringLiteral:
case LPAREN:
case LBRACK:
case BANG:
case TILDE:
case INC:
case DEC:
case ADD:
case SUB:
case Identifier:
enterOuterAlt(_localctx, 1);
{
setState(643);
expression(0);
}
break;
case ATSIGN:
enterOuterAlt(_localctx, 2);
{
setState(644);
annotation();
}
break;
case LBRACE:
enterOuterAlt(_localctx, 3);
{
setState(645);
elementValueArrayInitializer();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ElementValueArrayInitializerContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List elementValue() {
return getRuleContexts(ElementValueContext.class);
}
public ElementValueContext elementValue(int i) {
return getRuleContext(ElementValueContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public ElementValueArrayInitializerContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elementValueArrayInitializer; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterElementValueArrayInitializer(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitElementValueArrayInitializer(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitElementValueArrayInitializer(this);
else return visitor.visitChildren(this);
}
}
public final ElementValueArrayInitializerContext elementValueArrayInitializer() throws RecognitionException {
ElementValueArrayInitializerContext _localctx = new ElementValueArrayInitializerContext(_ctx, getState());
enterRule(_localctx, 76, RULE_elementValueArrayInitializer);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(648);
match(LBRACE);
setState(657);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACE - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (ATSIGN - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(649);
elementValue();
setState(654);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,48,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(650);
match(COMMA);
setState(651);
elementValue();
}
}
}
setState(656);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,48,_ctx);
}
}
}
setState(660);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==COMMA) {
{
setState(659);
match(COMMA);
}
}
setState(662);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class BlockContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List statement() {
return getRuleContexts(StatementContext.class);
}
public StatementContext statement(int i) {
return getRuleContext(StatementContext.class,i);
}
public BlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_block; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBlock(this);
else return visitor.visitChildren(this);
}
}
public final BlockContext block() throws RecognitionException {
BlockContext _localctx = new BlockContext(_ctx, getState());
enterRule(_localctx, 78, RULE_block);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(664);
match(LBRACE);
setState(668);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << BREAK) | (1L << CONTINUE) | (1L << DELETE) | (1L << DO) | (1L << FINAL) | (1L << FOR) | (1L << GET) | (1L << GLOBAL) | (1L << IF) | (1L << INHERITED) | (1L << INSERT) | (1L << INSTANCEOF) | (1L << MERGE) | (1L << NEW) | (1L << NULL) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << RETURN) | (1L << SYSTEMRUNAS) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SUPER) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << THIS) | (1L << THROW) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << TRY) | (1L << UNDELETE) | (1L << UPDATE) | (1L << UPSERT) | (1L << VIRTUAL) | (1L << VOID) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WHILE) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACE - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (ATSIGN - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
{
setState(665);
statement();
}
}
setState(670);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(671);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LocalVariableDeclarationStatementContext extends ParserRuleContext {
public LocalVariableDeclarationContext localVariableDeclaration() {
return getRuleContext(LocalVariableDeclarationContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public LocalVariableDeclarationStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_localVariableDeclarationStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLocalVariableDeclarationStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLocalVariableDeclarationStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLocalVariableDeclarationStatement(this);
else return visitor.visitChildren(this);
}
}
public final LocalVariableDeclarationStatementContext localVariableDeclarationStatement() throws RecognitionException {
LocalVariableDeclarationStatementContext _localctx = new LocalVariableDeclarationStatementContext(_ctx, getState());
enterRule(_localctx, 80, RULE_localVariableDeclarationStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(673);
localVariableDeclaration();
setState(674);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LocalVariableDeclarationContext extends ParserRuleContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public VariableDeclaratorsContext variableDeclarators() {
return getRuleContext(VariableDeclaratorsContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public LocalVariableDeclarationContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_localVariableDeclaration; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLocalVariableDeclaration(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLocalVariableDeclaration(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLocalVariableDeclaration(this);
else return visitor.visitChildren(this);
}
}
public final LocalVariableDeclarationContext localVariableDeclaration() throws RecognitionException {
LocalVariableDeclarationContext _localctx = new LocalVariableDeclarationContext(_ctx, getState());
enterRule(_localctx, 82, RULE_localVariableDeclaration);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(679);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,52,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(676);
modifier();
}
}
}
setState(681);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,52,_ctx);
}
setState(682);
typeRef();
setState(683);
variableDeclarators();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class StatementContext extends ParserRuleContext {
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public IfStatementContext ifStatement() {
return getRuleContext(IfStatementContext.class,0);
}
public SwitchStatementContext switchStatement() {
return getRuleContext(SwitchStatementContext.class,0);
}
public ForStatementContext forStatement() {
return getRuleContext(ForStatementContext.class,0);
}
public WhileStatementContext whileStatement() {
return getRuleContext(WhileStatementContext.class,0);
}
public DoWhileStatementContext doWhileStatement() {
return getRuleContext(DoWhileStatementContext.class,0);
}
public TryStatementContext tryStatement() {
return getRuleContext(TryStatementContext.class,0);
}
public ReturnStatementContext returnStatement() {
return getRuleContext(ReturnStatementContext.class,0);
}
public ThrowStatementContext throwStatement() {
return getRuleContext(ThrowStatementContext.class,0);
}
public BreakStatementContext breakStatement() {
return getRuleContext(BreakStatementContext.class,0);
}
public ContinueStatementContext continueStatement() {
return getRuleContext(ContinueStatementContext.class,0);
}
public InsertStatementContext insertStatement() {
return getRuleContext(InsertStatementContext.class,0);
}
public UpdateStatementContext updateStatement() {
return getRuleContext(UpdateStatementContext.class,0);
}
public DeleteStatementContext deleteStatement() {
return getRuleContext(DeleteStatementContext.class,0);
}
public UndeleteStatementContext undeleteStatement() {
return getRuleContext(UndeleteStatementContext.class,0);
}
public UpsertStatementContext upsertStatement() {
return getRuleContext(UpsertStatementContext.class,0);
}
public MergeStatementContext mergeStatement() {
return getRuleContext(MergeStatementContext.class,0);
}
public RunAsStatementContext runAsStatement() {
return getRuleContext(RunAsStatementContext.class,0);
}
public LocalVariableDeclarationStatementContext localVariableDeclarationStatement() {
return getRuleContext(LocalVariableDeclarationStatementContext.class,0);
}
public ExpressionStatementContext expressionStatement() {
return getRuleContext(ExpressionStatementContext.class,0);
}
public StatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_statement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitStatement(this);
else return visitor.visitChildren(this);
}
}
public final StatementContext statement() throws RecognitionException {
StatementContext _localctx = new StatementContext(_ctx, getState());
enterRule(_localctx, 84, RULE_statement);
try {
setState(705);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,53,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(685);
block();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(686);
ifStatement();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(687);
switchStatement();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(688);
forStatement();
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(689);
whileStatement();
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(690);
doWhileStatement();
}
break;
case 7:
enterOuterAlt(_localctx, 7);
{
setState(691);
tryStatement();
}
break;
case 8:
enterOuterAlt(_localctx, 8);
{
setState(692);
returnStatement();
}
break;
case 9:
enterOuterAlt(_localctx, 9);
{
setState(693);
throwStatement();
}
break;
case 10:
enterOuterAlt(_localctx, 10);
{
setState(694);
breakStatement();
}
break;
case 11:
enterOuterAlt(_localctx, 11);
{
setState(695);
continueStatement();
}
break;
case 12:
enterOuterAlt(_localctx, 12);
{
setState(696);
insertStatement();
}
break;
case 13:
enterOuterAlt(_localctx, 13);
{
setState(697);
updateStatement();
}
break;
case 14:
enterOuterAlt(_localctx, 14);
{
setState(698);
deleteStatement();
}
break;
case 15:
enterOuterAlt(_localctx, 15);
{
setState(699);
undeleteStatement();
}
break;
case 16:
enterOuterAlt(_localctx, 16);
{
setState(700);
upsertStatement();
}
break;
case 17:
enterOuterAlt(_localctx, 17);
{
setState(701);
mergeStatement();
}
break;
case 18:
enterOuterAlt(_localctx, 18);
{
setState(702);
runAsStatement();
}
break;
case 19:
enterOuterAlt(_localctx, 19);
{
setState(703);
localVariableDeclarationStatement();
}
break;
case 20:
enterOuterAlt(_localctx, 20);
{
setState(704);
expressionStatement();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class IfStatementContext extends ParserRuleContext {
public TerminalNode IF() { return getToken(ApexParser.IF, 0); }
public ParExpressionContext parExpression() {
return getRuleContext(ParExpressionContext.class,0);
}
public List statement() {
return getRuleContexts(StatementContext.class);
}
public StatementContext statement(int i) {
return getRuleContext(StatementContext.class,i);
}
public TerminalNode ELSE() { return getToken(ApexParser.ELSE, 0); }
public IfStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_ifStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterIfStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitIfStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitIfStatement(this);
else return visitor.visitChildren(this);
}
}
public final IfStatementContext ifStatement() throws RecognitionException {
IfStatementContext _localctx = new IfStatementContext(_ctx, getState());
enterRule(_localctx, 86, RULE_ifStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(707);
match(IF);
setState(708);
parExpression();
setState(709);
statement();
setState(712);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,54,_ctx) ) {
case 1:
{
setState(710);
match(ELSE);
setState(711);
statement();
}
break;
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SwitchStatementContext extends ParserRuleContext {
public TerminalNode SWITCH() { return getToken(ApexParser.SWITCH, 0); }
public TerminalNode ON() { return getToken(ApexParser.ON, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List whenControl() {
return getRuleContexts(WhenControlContext.class);
}
public WhenControlContext whenControl(int i) {
return getRuleContext(WhenControlContext.class,i);
}
public SwitchStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_switchStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSwitchStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSwitchStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSwitchStatement(this);
else return visitor.visitChildren(this);
}
}
public final SwitchStatementContext switchStatement() throws RecognitionException {
SwitchStatementContext _localctx = new SwitchStatementContext(_ctx, getState());
enterRule(_localctx, 88, RULE_switchStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(714);
match(SWITCH);
setState(715);
match(ON);
setState(716);
expression(0);
setState(717);
match(LBRACE);
setState(719);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(718);
whenControl();
}
}
setState(721);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==WHEN );
setState(723);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhenControlContext extends ParserRuleContext {
public TerminalNode WHEN() { return getToken(ApexParser.WHEN, 0); }
public WhenValueContext whenValue() {
return getRuleContext(WhenValueContext.class,0);
}
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public WhenControlContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whenControl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhenControl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhenControl(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhenControl(this);
else return visitor.visitChildren(this);
}
}
public final WhenControlContext whenControl() throws RecognitionException {
WhenControlContext _localctx = new WhenControlContext(_ctx, getState());
enterRule(_localctx, 90, RULE_whenControl);
try {
enterOuterAlt(_localctx, 1);
{
setState(725);
match(WHEN);
setState(726);
whenValue();
setState(727);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhenValueContext extends ParserRuleContext {
public TerminalNode ELSE() { return getToken(ApexParser.ELSE, 0); }
public List whenLiteral() {
return getRuleContexts(WhenLiteralContext.class);
}
public WhenLiteralContext whenLiteral(int i) {
return getRuleContext(WhenLiteralContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public WhenValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whenValue; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhenValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhenValue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhenValue(this);
else return visitor.visitChildren(this);
}
}
public final WhenValueContext whenValue() throws RecognitionException {
WhenValueContext _localctx = new WhenValueContext(_ctx, getState());
enterRule(_localctx, 92, RULE_whenValue);
int _la;
try {
setState(741);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,57,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(729);
match(ELSE);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(730);
whenLiteral();
setState(735);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(731);
match(COMMA);
setState(732);
whenLiteral();
}
}
setState(737);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(738);
typeRef();
setState(739);
id();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhenLiteralContext extends ParserRuleContext {
public TerminalNode IntegerLiteral() { return getToken(ApexParser.IntegerLiteral, 0); }
public List SUB() { return getTokens(ApexParser.SUB); }
public TerminalNode SUB(int i) {
return getToken(ApexParser.SUB, i);
}
public List ADD() { return getTokens(ApexParser.ADD); }
public TerminalNode ADD(int i) {
return getToken(ApexParser.ADD, i);
}
public TerminalNode LongLiteral() { return getToken(ApexParser.LongLiteral, 0); }
public TerminalNode StringLiteral() { return getToken(ApexParser.StringLiteral, 0); }
public TerminalNode NULL() { return getToken(ApexParser.NULL, 0); }
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public WhenLiteralContext whenLiteral() {
return getRuleContext(WhenLiteralContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public WhenLiteralContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whenLiteral; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhenLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhenLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhenLiteral(this);
else return visitor.visitChildren(this);
}
}
public final WhenLiteralContext whenLiteral() throws RecognitionException {
WhenLiteralContext _localctx = new WhenLiteralContext(_ctx, getState());
enterRule(_localctx, 94, RULE_whenLiteral);
int _la;
try {
setState(764);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,60,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(746);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==ADD || _la==SUB) {
{
{
setState(743);
_la = _input.LA(1);
if ( !(_la==ADD || _la==SUB) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(748);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(749);
match(IntegerLiteral);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(753);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==ADD || _la==SUB) {
{
{
setState(750);
_la = _input.LA(1);
if ( !(_la==ADD || _la==SUB) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(755);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(756);
match(LongLiteral);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(757);
match(StringLiteral);
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(758);
match(NULL);
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(759);
id();
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(760);
match(LPAREN);
setState(761);
whenLiteral();
setState(762);
match(RPAREN);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ForStatementContext extends ParserRuleContext {
public TerminalNode FOR() { return getToken(ApexParser.FOR, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public ForControlContext forControl() {
return getRuleContext(ForControlContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public ForStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_forStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterForStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitForStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitForStatement(this);
else return visitor.visitChildren(this);
}
}
public final ForStatementContext forStatement() throws RecognitionException {
ForStatementContext _localctx = new ForStatementContext(_ctx, getState());
enterRule(_localctx, 96, RULE_forStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(766);
match(FOR);
setState(767);
match(LPAREN);
setState(768);
forControl();
setState(769);
match(RPAREN);
setState(772);
_errHandler.sync(this);
switch (_input.LA(1)) {
case ABSTRACT:
case AFTER:
case BEFORE:
case BREAK:
case CONTINUE:
case DELETE:
case DO:
case FINAL:
case FOR:
case GET:
case GLOBAL:
case IF:
case INHERITED:
case INSERT:
case INSTANCEOF:
case MERGE:
case NEW:
case NULL:
case OVERRIDE:
case PRIVATE:
case PROTECTED:
case PUBLIC:
case RETURN:
case SYSTEMRUNAS:
case SET:
case SHARING:
case STATIC:
case SUPER:
case SWITCH:
case TESTMETHOD:
case THIS:
case THROW:
case TRANSIENT:
case TRIGGER:
case TRY:
case UNDELETE:
case UPDATE:
case UPSERT:
case VIRTUAL:
case VOID:
case WEBSERVICE:
case WHEN:
case WHILE:
case WITH:
case WITHOUT:
case LIST:
case MAP:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case FindLiteral:
case IntegerLiteral:
case LongLiteral:
case NumberLiteral:
case BooleanLiteral:
case StringLiteral:
case LPAREN:
case LBRACE:
case LBRACK:
case BANG:
case TILDE:
case INC:
case DEC:
case ADD:
case SUB:
case ATSIGN:
case Identifier:
{
setState(770);
statement();
}
break;
case SEMI:
{
setState(771);
match(SEMI);
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhileStatementContext extends ParserRuleContext {
public TerminalNode WHILE() { return getToken(ApexParser.WHILE, 0); }
public ParExpressionContext parExpression() {
return getRuleContext(ParExpressionContext.class,0);
}
public StatementContext statement() {
return getRuleContext(StatementContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public WhileStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whileStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhileStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhileStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhileStatement(this);
else return visitor.visitChildren(this);
}
}
public final WhileStatementContext whileStatement() throws RecognitionException {
WhileStatementContext _localctx = new WhileStatementContext(_ctx, getState());
enterRule(_localctx, 98, RULE_whileStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(774);
match(WHILE);
setState(775);
parExpression();
setState(778);
_errHandler.sync(this);
switch (_input.LA(1)) {
case ABSTRACT:
case AFTER:
case BEFORE:
case BREAK:
case CONTINUE:
case DELETE:
case DO:
case FINAL:
case FOR:
case GET:
case GLOBAL:
case IF:
case INHERITED:
case INSERT:
case INSTANCEOF:
case MERGE:
case NEW:
case NULL:
case OVERRIDE:
case PRIVATE:
case PROTECTED:
case PUBLIC:
case RETURN:
case SYSTEMRUNAS:
case SET:
case SHARING:
case STATIC:
case SUPER:
case SWITCH:
case TESTMETHOD:
case THIS:
case THROW:
case TRANSIENT:
case TRIGGER:
case TRY:
case UNDELETE:
case UPDATE:
case UPSERT:
case VIRTUAL:
case VOID:
case WEBSERVICE:
case WHEN:
case WHILE:
case WITH:
case WITHOUT:
case LIST:
case MAP:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case FindLiteral:
case IntegerLiteral:
case LongLiteral:
case NumberLiteral:
case BooleanLiteral:
case StringLiteral:
case LPAREN:
case LBRACE:
case LBRACK:
case BANG:
case TILDE:
case INC:
case DEC:
case ADD:
case SUB:
case ATSIGN:
case Identifier:
{
setState(776);
statement();
}
break;
case SEMI:
{
setState(777);
match(SEMI);
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DoWhileStatementContext extends ParserRuleContext {
public TerminalNode DO() { return getToken(ApexParser.DO, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public TerminalNode WHILE() { return getToken(ApexParser.WHILE, 0); }
public ParExpressionContext parExpression() {
return getRuleContext(ParExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public DoWhileStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_doWhileStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDoWhileStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDoWhileStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDoWhileStatement(this);
else return visitor.visitChildren(this);
}
}
public final DoWhileStatementContext doWhileStatement() throws RecognitionException {
DoWhileStatementContext _localctx = new DoWhileStatementContext(_ctx, getState());
enterRule(_localctx, 100, RULE_doWhileStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(780);
match(DO);
setState(781);
block();
setState(782);
match(WHILE);
setState(783);
parExpression();
setState(784);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TryStatementContext extends ParserRuleContext {
public TerminalNode TRY() { return getToken(ApexParser.TRY, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public FinallyBlockContext finallyBlock() {
return getRuleContext(FinallyBlockContext.class,0);
}
public List catchClause() {
return getRuleContexts(CatchClauseContext.class);
}
public CatchClauseContext catchClause(int i) {
return getRuleContext(CatchClauseContext.class,i);
}
public TryStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_tryStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTryStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTryStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTryStatement(this);
else return visitor.visitChildren(this);
}
}
public final TryStatementContext tryStatement() throws RecognitionException {
TryStatementContext _localctx = new TryStatementContext(_ctx, getState());
enterRule(_localctx, 102, RULE_tryStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(786);
match(TRY);
setState(787);
block();
setState(797);
_errHandler.sync(this);
switch (_input.LA(1)) {
case CATCH:
{
setState(789);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(788);
catchClause();
}
}
setState(791);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==CATCH );
setState(794);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==FINALLY) {
{
setState(793);
finallyBlock();
}
}
}
break;
case FINALLY:
{
setState(796);
finallyBlock();
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ReturnStatementContext extends ParserRuleContext {
public TerminalNode RETURN() { return getToken(ApexParser.RETURN, 0); }
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public ReturnStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_returnStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterReturnStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitReturnStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitReturnStatement(this);
else return visitor.visitChildren(this);
}
}
public final ReturnStatementContext returnStatement() throws RecognitionException {
ReturnStatementContext _localctx = new ReturnStatementContext(_ctx, getState());
enterRule(_localctx, 104, RULE_returnStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(799);
match(RETURN);
setState(801);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(800);
expression(0);
}
}
setState(803);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ThrowStatementContext extends ParserRuleContext {
public TerminalNode THROW() { return getToken(ApexParser.THROW, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public ThrowStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_throwStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterThrowStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitThrowStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitThrowStatement(this);
else return visitor.visitChildren(this);
}
}
public final ThrowStatementContext throwStatement() throws RecognitionException {
ThrowStatementContext _localctx = new ThrowStatementContext(_ctx, getState());
enterRule(_localctx, 106, RULE_throwStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(805);
match(THROW);
setState(806);
expression(0);
setState(807);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class BreakStatementContext extends ParserRuleContext {
public TerminalNode BREAK() { return getToken(ApexParser.BREAK, 0); }
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public BreakStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_breakStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBreakStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBreakStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBreakStatement(this);
else return visitor.visitChildren(this);
}
}
public final BreakStatementContext breakStatement() throws RecognitionException {
BreakStatementContext _localctx = new BreakStatementContext(_ctx, getState());
enterRule(_localctx, 108, RULE_breakStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(809);
match(BREAK);
setState(810);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ContinueStatementContext extends ParserRuleContext {
public TerminalNode CONTINUE() { return getToken(ApexParser.CONTINUE, 0); }
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public ContinueStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_continueStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterContinueStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitContinueStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitContinueStatement(this);
else return visitor.visitChildren(this);
}
}
public final ContinueStatementContext continueStatement() throws RecognitionException {
ContinueStatementContext _localctx = new ContinueStatementContext(_ctx, getState());
enterRule(_localctx, 110, RULE_continueStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(812);
match(CONTINUE);
setState(813);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class AccessLevelContext extends ParserRuleContext {
public TerminalNode AS() { return getToken(ApexParser.AS, 0); }
public TerminalNode SYSTEM() { return getToken(ApexParser.SYSTEM, 0); }
public TerminalNode USER() { return getToken(ApexParser.USER, 0); }
public AccessLevelContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_accessLevel; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterAccessLevel(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitAccessLevel(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitAccessLevel(this);
else return visitor.visitChildren(this);
}
}
public final AccessLevelContext accessLevel() throws RecognitionException {
AccessLevelContext _localctx = new AccessLevelContext(_ctx, getState());
enterRule(_localctx, 112, RULE_accessLevel);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(815);
match(AS);
setState(816);
_la = _input.LA(1);
if ( !(_la==SYSTEM || _la==USER) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class InsertStatementContext extends ParserRuleContext {
public TerminalNode INSERT() { return getToken(ApexParser.INSERT, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public InsertStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_insertStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterInsertStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitInsertStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitInsertStatement(this);
else return visitor.visitChildren(this);
}
}
public final InsertStatementContext insertStatement() throws RecognitionException {
InsertStatementContext _localctx = new InsertStatementContext(_ctx, getState());
enterRule(_localctx, 114, RULE_insertStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(818);
match(INSERT);
setState(820);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,67,_ctx) ) {
case 1:
{
setState(819);
accessLevel();
}
break;
}
setState(822);
expression(0);
setState(823);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class UpdateStatementContext extends ParserRuleContext {
public TerminalNode UPDATE() { return getToken(ApexParser.UPDATE, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public UpdateStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_updateStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterUpdateStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitUpdateStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitUpdateStatement(this);
else return visitor.visitChildren(this);
}
}
public final UpdateStatementContext updateStatement() throws RecognitionException {
UpdateStatementContext _localctx = new UpdateStatementContext(_ctx, getState());
enterRule(_localctx, 116, RULE_updateStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(825);
match(UPDATE);
setState(827);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,68,_ctx) ) {
case 1:
{
setState(826);
accessLevel();
}
break;
}
setState(829);
expression(0);
setState(830);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DeleteStatementContext extends ParserRuleContext {
public TerminalNode DELETE() { return getToken(ApexParser.DELETE, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public DeleteStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_deleteStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDeleteStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDeleteStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDeleteStatement(this);
else return visitor.visitChildren(this);
}
}
public final DeleteStatementContext deleteStatement() throws RecognitionException {
DeleteStatementContext _localctx = new DeleteStatementContext(_ctx, getState());
enterRule(_localctx, 118, RULE_deleteStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(832);
match(DELETE);
setState(834);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,69,_ctx) ) {
case 1:
{
setState(833);
accessLevel();
}
break;
}
setState(836);
expression(0);
setState(837);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class UndeleteStatementContext extends ParserRuleContext {
public TerminalNode UNDELETE() { return getToken(ApexParser.UNDELETE, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public UndeleteStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_undeleteStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterUndeleteStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitUndeleteStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitUndeleteStatement(this);
else return visitor.visitChildren(this);
}
}
public final UndeleteStatementContext undeleteStatement() throws RecognitionException {
UndeleteStatementContext _localctx = new UndeleteStatementContext(_ctx, getState());
enterRule(_localctx, 120, RULE_undeleteStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(839);
match(UNDELETE);
setState(841);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,70,_ctx) ) {
case 1:
{
setState(840);
accessLevel();
}
break;
}
setState(843);
expression(0);
setState(844);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class UpsertStatementContext extends ParserRuleContext {
public TerminalNode UPSERT() { return getToken(ApexParser.UPSERT, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public QualifiedNameContext qualifiedName() {
return getRuleContext(QualifiedNameContext.class,0);
}
public UpsertStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_upsertStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterUpsertStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitUpsertStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitUpsertStatement(this);
else return visitor.visitChildren(this);
}
}
public final UpsertStatementContext upsertStatement() throws RecognitionException {
UpsertStatementContext _localctx = new UpsertStatementContext(_ctx, getState());
enterRule(_localctx, 122, RULE_upsertStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(846);
match(UPSERT);
setState(848);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,71,_ctx) ) {
case 1:
{
setState(847);
accessLevel();
}
break;
}
setState(850);
expression(0);
setState(852);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << SET) | (1L << SHARING) | (1L << SWITCH) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || _la==Identifier) {
{
setState(851);
qualifiedName();
}
}
setState(854);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MergeStatementContext extends ParserRuleContext {
public TerminalNode MERGE() { return getToken(ApexParser.MERGE, 0); }
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public AccessLevelContext accessLevel() {
return getRuleContext(AccessLevelContext.class,0);
}
public MergeStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_mergeStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMergeStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMergeStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMergeStatement(this);
else return visitor.visitChildren(this);
}
}
public final MergeStatementContext mergeStatement() throws RecognitionException {
MergeStatementContext _localctx = new MergeStatementContext(_ctx, getState());
enterRule(_localctx, 124, RULE_mergeStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(856);
match(MERGE);
setState(858);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,73,_ctx) ) {
case 1:
{
setState(857);
accessLevel();
}
break;
}
setState(860);
expression(0);
setState(861);
expression(0);
setState(862);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class RunAsStatementContext extends ParserRuleContext {
public TerminalNode SYSTEMRUNAS() { return getToken(ApexParser.SYSTEMRUNAS, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public RunAsStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_runAsStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterRunAsStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitRunAsStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitRunAsStatement(this);
else return visitor.visitChildren(this);
}
}
public final RunAsStatementContext runAsStatement() throws RecognitionException {
RunAsStatementContext _localctx = new RunAsStatementContext(_ctx, getState());
enterRule(_localctx, 126, RULE_runAsStatement);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(864);
match(SYSTEMRUNAS);
setState(865);
match(LPAREN);
setState(867);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(866);
expressionList();
}
}
setState(869);
match(RPAREN);
setState(870);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ExpressionStatementContext extends ParserRuleContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public ExpressionStatementContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_expressionStatement; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterExpressionStatement(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitExpressionStatement(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitExpressionStatement(this);
else return visitor.visitChildren(this);
}
}
public final ExpressionStatementContext expressionStatement() throws RecognitionException {
ExpressionStatementContext _localctx = new ExpressionStatementContext(_ctx, getState());
enterRule(_localctx, 128, RULE_expressionStatement);
try {
enterOuterAlt(_localctx, 1);
{
setState(872);
expression(0);
setState(873);
match(SEMI);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class PropertyBlockContext extends ParserRuleContext {
public GetterContext getter() {
return getRuleContext(GetterContext.class,0);
}
public SetterContext setter() {
return getRuleContext(SetterContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public PropertyBlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_propertyBlock; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterPropertyBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitPropertyBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitPropertyBlock(this);
else return visitor.visitChildren(this);
}
}
public final PropertyBlockContext propertyBlock() throws RecognitionException {
PropertyBlockContext _localctx = new PropertyBlockContext(_ctx, getState());
enterRule(_localctx, 130, RULE_propertyBlock);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(878);
_errHandler.sync(this);
_la = _input.LA(1);
while ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << FINAL) | (1L << GLOBAL) | (1L << INHERITED) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << STATIC) | (1L << TESTMETHOD) | (1L << TRANSIENT) | (1L << VIRTUAL) | (1L << WEBSERVICE) | (1L << WITH) | (1L << WITHOUT))) != 0) || _la==ATSIGN) {
{
{
setState(875);
modifier();
}
}
setState(880);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(883);
_errHandler.sync(this);
switch (_input.LA(1)) {
case GET:
{
setState(881);
getter();
}
break;
case SET:
{
setState(882);
setter();
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class GetterContext extends ParserRuleContext {
public TerminalNode GET() { return getToken(ApexParser.GET, 0); }
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public GetterContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_getter; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterGetter(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitGetter(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitGetter(this);
else return visitor.visitChildren(this);
}
}
public final GetterContext getter() throws RecognitionException {
GetterContext _localctx = new GetterContext(_ctx, getState());
enterRule(_localctx, 132, RULE_getter);
try {
enterOuterAlt(_localctx, 1);
{
setState(885);
match(GET);
setState(888);
_errHandler.sync(this);
switch (_input.LA(1)) {
case SEMI:
{
setState(886);
match(SEMI);
}
break;
case LBRACE:
{
setState(887);
block();
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SetterContext extends ParserRuleContext {
public TerminalNode SET() { return getToken(ApexParser.SET, 0); }
public TerminalNode SEMI() { return getToken(ApexParser.SEMI, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public SetterContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_setter; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSetter(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSetter(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSetter(this);
else return visitor.visitChildren(this);
}
}
public final SetterContext setter() throws RecognitionException {
SetterContext _localctx = new SetterContext(_ctx, getState());
enterRule(_localctx, 134, RULE_setter);
try {
enterOuterAlt(_localctx, 1);
{
setState(890);
match(SET);
setState(893);
_errHandler.sync(this);
switch (_input.LA(1)) {
case SEMI:
{
setState(891);
match(SEMI);
}
break;
case LBRACE:
{
setState(892);
block();
}
break;
default:
throw new NoViableAltException(this);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CatchClauseContext extends ParserRuleContext {
public TerminalNode CATCH() { return getToken(ApexParser.CATCH, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public QualifiedNameContext qualifiedName() {
return getRuleContext(QualifiedNameContext.class,0);
}
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public List modifier() {
return getRuleContexts(ModifierContext.class);
}
public ModifierContext modifier(int i) {
return getRuleContext(ModifierContext.class,i);
}
public CatchClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_catchClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCatchClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCatchClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCatchClause(this);
else return visitor.visitChildren(this);
}
}
public final CatchClauseContext catchClause() throws RecognitionException {
CatchClauseContext _localctx = new CatchClauseContext(_ctx, getState());
enterRule(_localctx, 136, RULE_catchClause);
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(895);
match(CATCH);
setState(896);
match(LPAREN);
setState(900);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,79,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
{
{
setState(897);
modifier();
}
}
}
setState(902);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,79,_ctx);
}
setState(903);
qualifiedName();
setState(904);
id();
setState(905);
match(RPAREN);
setState(906);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FinallyBlockContext extends ParserRuleContext {
public TerminalNode FINALLY() { return getToken(ApexParser.FINALLY, 0); }
public BlockContext block() {
return getRuleContext(BlockContext.class,0);
}
public FinallyBlockContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_finallyBlock; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFinallyBlock(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFinallyBlock(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFinallyBlock(this);
else return visitor.visitChildren(this);
}
}
public final FinallyBlockContext finallyBlock() throws RecognitionException {
FinallyBlockContext _localctx = new FinallyBlockContext(_ctx, getState());
enterRule(_localctx, 138, RULE_finallyBlock);
try {
enterOuterAlt(_localctx, 1);
{
setState(908);
match(FINALLY);
setState(909);
block();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ForControlContext extends ParserRuleContext {
public EnhancedForControlContext enhancedForControl() {
return getRuleContext(EnhancedForControlContext.class,0);
}
public List SEMI() { return getTokens(ApexParser.SEMI); }
public TerminalNode SEMI(int i) {
return getToken(ApexParser.SEMI, i);
}
public ForInitContext forInit() {
return getRuleContext(ForInitContext.class,0);
}
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public ForUpdateContext forUpdate() {
return getRuleContext(ForUpdateContext.class,0);
}
public ForControlContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_forControl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterForControl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitForControl(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitForControl(this);
else return visitor.visitChildren(this);
}
}
public final ForControlContext forControl() throws RecognitionException {
ForControlContext _localctx = new ForControlContext(_ctx, getState());
enterRule(_localctx, 140, RULE_forControl);
int _la;
try {
setState(923);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,83,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(911);
enhancedForControl();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(913);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << ABSTRACT) | (1L << AFTER) | (1L << BEFORE) | (1L << FINAL) | (1L << GET) | (1L << GLOBAL) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << OVERRIDE) | (1L << PRIVATE) | (1L << PROTECTED) | (1L << PUBLIC) | (1L << SET) | (1L << SHARING) | (1L << STATIC) | (1L << SUPER) | (1L << SWITCH) | (1L << TESTMETHOD) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VIRTUAL) | (1L << VOID) | (1L << WEBSERVICE) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (ATSIGN - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(912);
forInit();
}
}
setState(915);
match(SEMI);
setState(917);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(916);
expression(0);
}
}
setState(919);
match(SEMI);
setState(921);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(920);
forUpdate();
}
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ForInitContext extends ParserRuleContext {
public LocalVariableDeclarationContext localVariableDeclaration() {
return getRuleContext(LocalVariableDeclarationContext.class,0);
}
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public ForInitContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_forInit; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterForInit(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitForInit(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitForInit(this);
else return visitor.visitChildren(this);
}
}
public final ForInitContext forInit() throws RecognitionException {
ForInitContext _localctx = new ForInitContext(_ctx, getState());
enterRule(_localctx, 142, RULE_forInit);
try {
setState(927);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,84,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(925);
localVariableDeclaration();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(926);
expressionList();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class EnhancedForControlContext extends ParserRuleContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode COLON() { return getToken(ApexParser.COLON, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public EnhancedForControlContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_enhancedForControl; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterEnhancedForControl(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitEnhancedForControl(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitEnhancedForControl(this);
else return visitor.visitChildren(this);
}
}
public final EnhancedForControlContext enhancedForControl() throws RecognitionException {
EnhancedForControlContext _localctx = new EnhancedForControlContext(_ctx, getState());
enterRule(_localctx, 144, RULE_enhancedForControl);
try {
enterOuterAlt(_localctx, 1);
{
setState(929);
typeRef();
setState(930);
id();
setState(931);
match(COLON);
setState(932);
expression(0);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ForUpdateContext extends ParserRuleContext {
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public ForUpdateContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_forUpdate; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterForUpdate(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitForUpdate(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitForUpdate(this);
else return visitor.visitChildren(this);
}
}
public final ForUpdateContext forUpdate() throws RecognitionException {
ForUpdateContext _localctx = new ForUpdateContext(_ctx, getState());
enterRule(_localctx, 146, RULE_forUpdate);
try {
enterOuterAlt(_localctx, 1);
{
setState(934);
expressionList();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ParExpressionContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ParExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_parExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterParExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitParExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitParExpression(this);
else return visitor.visitChildren(this);
}
}
public final ParExpressionContext parExpression() throws RecognitionException {
ParExpressionContext _localctx = new ParExpressionContext(_ctx, getState());
enterRule(_localctx, 148, RULE_parExpression);
try {
enterOuterAlt(_localctx, 1);
{
setState(936);
match(LPAREN);
setState(937);
expression(0);
setState(938);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ExpressionListContext extends ParserRuleContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public ExpressionListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_expressionList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterExpressionList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitExpressionList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitExpressionList(this);
else return visitor.visitChildren(this);
}
}
public final ExpressionListContext expressionList() throws RecognitionException {
ExpressionListContext _localctx = new ExpressionListContext(_ctx, getState());
enterRule(_localctx, 150, RULE_expressionList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(940);
expression(0);
setState(945);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(941);
match(COMMA);
setState(942);
expression(0);
}
}
setState(947);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ExpressionContext extends ParserRuleContext {
public ExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_expression; }
public ExpressionContext() { }
public void copyFrom(ExpressionContext ctx) {
super.copyFrom(ctx);
}
}
public static class PrimaryExpressionContext extends ExpressionContext {
public PrimaryContext primary() {
return getRuleContext(PrimaryContext.class,0);
}
public PrimaryExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterPrimaryExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitPrimaryExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitPrimaryExpression(this);
else return visitor.visitChildren(this);
}
}
public static class Arth1ExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode MUL() { return getToken(ApexParser.MUL, 0); }
public TerminalNode DIV() { return getToken(ApexParser.DIV, 0); }
public Arth1ExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArth1Expression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArth1Expression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArth1Expression(this);
else return visitor.visitChildren(this);
}
}
public static class CoalExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode COAL() { return getToken(ApexParser.COAL, 0); }
public CoalExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCoalExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCoalExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCoalExpression(this);
else return visitor.visitChildren(this);
}
}
public static class DotExpressionContext extends ExpressionContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode DOT() { return getToken(ApexParser.DOT, 0); }
public TerminalNode QUESTIONDOT() { return getToken(ApexParser.QUESTIONDOT, 0); }
public DotMethodCallContext dotMethodCall() {
return getRuleContext(DotMethodCallContext.class,0);
}
public AnyIdContext anyId() {
return getRuleContext(AnyIdContext.class,0);
}
public DotExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDotExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDotExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDotExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BitOrExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode BITOR() { return getToken(ApexParser.BITOR, 0); }
public BitOrExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBitOrExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBitOrExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBitOrExpression(this);
else return visitor.visitChildren(this);
}
}
public static class ArrayExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode LBRACK() { return getToken(ApexParser.LBRACK, 0); }
public TerminalNode RBRACK() { return getToken(ApexParser.RBRACK, 0); }
public ArrayExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArrayExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArrayExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArrayExpression(this);
else return visitor.visitChildren(this);
}
}
public static class NewExpressionContext extends ExpressionContext {
public TerminalNode NEW() { return getToken(ApexParser.NEW, 0); }
public CreatorContext creator() {
return getRuleContext(CreatorContext.class,0);
}
public NewExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterNewExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitNewExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitNewExpression(this);
else return visitor.visitChildren(this);
}
}
public static class AssignExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode ASSIGN() { return getToken(ApexParser.ASSIGN, 0); }
public TerminalNode ADD_ASSIGN() { return getToken(ApexParser.ADD_ASSIGN, 0); }
public TerminalNode SUB_ASSIGN() { return getToken(ApexParser.SUB_ASSIGN, 0); }
public TerminalNode MUL_ASSIGN() { return getToken(ApexParser.MUL_ASSIGN, 0); }
public TerminalNode DIV_ASSIGN() { return getToken(ApexParser.DIV_ASSIGN, 0); }
public TerminalNode AND_ASSIGN() { return getToken(ApexParser.AND_ASSIGN, 0); }
public TerminalNode OR_ASSIGN() { return getToken(ApexParser.OR_ASSIGN, 0); }
public TerminalNode XOR_ASSIGN() { return getToken(ApexParser.XOR_ASSIGN, 0); }
public TerminalNode RSHIFT_ASSIGN() { return getToken(ApexParser.RSHIFT_ASSIGN, 0); }
public TerminalNode URSHIFT_ASSIGN() { return getToken(ApexParser.URSHIFT_ASSIGN, 0); }
public TerminalNode LSHIFT_ASSIGN() { return getToken(ApexParser.LSHIFT_ASSIGN, 0); }
public AssignExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterAssignExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitAssignExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitAssignExpression(this);
else return visitor.visitChildren(this);
}
}
public static class MethodCallExpressionContext extends ExpressionContext {
public MethodCallContext methodCall() {
return getRuleContext(MethodCallContext.class,0);
}
public MethodCallExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMethodCallExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMethodCallExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMethodCallExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BitNotExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode CARET() { return getToken(ApexParser.CARET, 0); }
public BitNotExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBitNotExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBitNotExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBitNotExpression(this);
else return visitor.visitChildren(this);
}
}
public static class Arth2ExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode ADD() { return getToken(ApexParser.ADD, 0); }
public TerminalNode SUB() { return getToken(ApexParser.SUB, 0); }
public Arth2ExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArth2Expression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArth2Expression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArth2Expression(this);
else return visitor.visitChildren(this);
}
}
public static class LogAndExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode AND() { return getToken(ApexParser.AND, 0); }
public LogAndExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLogAndExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLogAndExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLogAndExpression(this);
else return visitor.visitChildren(this);
}
}
public static class CastExpressionContext extends ExpressionContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public CastExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCastExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCastExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCastExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BitAndExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode BITAND() { return getToken(ApexParser.BITAND, 0); }
public BitAndExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBitAndExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBitAndExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBitAndExpression(this);
else return visitor.visitChildren(this);
}
}
public static class CmpExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode GT() { return getToken(ApexParser.GT, 0); }
public TerminalNode LT() { return getToken(ApexParser.LT, 0); }
public TerminalNode ASSIGN() { return getToken(ApexParser.ASSIGN, 0); }
public CmpExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCmpExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCmpExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCmpExpression(this);
else return visitor.visitChildren(this);
}
}
public static class BitExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public List LT() { return getTokens(ApexParser.LT); }
public TerminalNode LT(int i) {
return getToken(ApexParser.LT, i);
}
public List GT() { return getTokens(ApexParser.GT); }
public TerminalNode GT(int i) {
return getToken(ApexParser.GT, i);
}
public BitExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterBitExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitBitExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitBitExpression(this);
else return visitor.visitChildren(this);
}
}
public static class LogOrExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode OR() { return getToken(ApexParser.OR, 0); }
public LogOrExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLogOrExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLogOrExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLogOrExpression(this);
else return visitor.visitChildren(this);
}
}
public static class CondExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode QUESTION() { return getToken(ApexParser.QUESTION, 0); }
public TerminalNode COLON() { return getToken(ApexParser.COLON, 0); }
public CondExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCondExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCondExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCondExpression(this);
else return visitor.visitChildren(this);
}
}
public static class EqualityExpressionContext extends ExpressionContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode TRIPLEEQUAL() { return getToken(ApexParser.TRIPLEEQUAL, 0); }
public TerminalNode TRIPLENOTEQUAL() { return getToken(ApexParser.TRIPLENOTEQUAL, 0); }
public TerminalNode EQUAL() { return getToken(ApexParser.EQUAL, 0); }
public TerminalNode NOTEQUAL() { return getToken(ApexParser.NOTEQUAL, 0); }
public TerminalNode LESSANDGREATER() { return getToken(ApexParser.LESSANDGREATER, 0); }
public EqualityExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterEqualityExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitEqualityExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitEqualityExpression(this);
else return visitor.visitChildren(this);
}
}
public static class PostOpExpressionContext extends ExpressionContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode INC() { return getToken(ApexParser.INC, 0); }
public TerminalNode DEC() { return getToken(ApexParser.DEC, 0); }
public PostOpExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterPostOpExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitPostOpExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitPostOpExpression(this);
else return visitor.visitChildren(this);
}
}
public static class NegExpressionContext extends ExpressionContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode TILDE() { return getToken(ApexParser.TILDE, 0); }
public TerminalNode BANG() { return getToken(ApexParser.BANG, 0); }
public NegExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterNegExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitNegExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitNegExpression(this);
else return visitor.visitChildren(this);
}
}
public static class PreOpExpressionContext extends ExpressionContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode ADD() { return getToken(ApexParser.ADD, 0); }
public TerminalNode SUB() { return getToken(ApexParser.SUB, 0); }
public TerminalNode INC() { return getToken(ApexParser.INC, 0); }
public TerminalNode DEC() { return getToken(ApexParser.DEC, 0); }
public PreOpExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterPreOpExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitPreOpExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitPreOpExpression(this);
else return visitor.visitChildren(this);
}
}
public static class SubExpressionContext extends ExpressionContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public SubExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSubExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSubExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSubExpression(this);
else return visitor.visitChildren(this);
}
}
public static class InstanceOfExpressionContext extends ExpressionContext {
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode INSTANCEOF() { return getToken(ApexParser.INSTANCEOF, 0); }
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public InstanceOfExpressionContext(ExpressionContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterInstanceOfExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitInstanceOfExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitInstanceOfExpression(this);
else return visitor.visitChildren(this);
}
}
public final ExpressionContext expression() throws RecognitionException {
return expression(0);
}
private ExpressionContext expression(int _p) throws RecognitionException {
ParserRuleContext _parentctx = _ctx;
int _parentState = getState();
ExpressionContext _localctx = new ExpressionContext(_ctx, _parentState);
ExpressionContext _prevctx = _localctx;
int _startState = 152;
enterRecursionRule(_localctx, 152, RULE_expression, _p);
int _la;
try {
int _alt;
enterOuterAlt(_localctx, 1);
{
setState(966);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,86,_ctx) ) {
case 1:
{
_localctx = new PrimaryExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(949);
primary();
}
break;
case 2:
{
_localctx = new MethodCallExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(950);
methodCall();
}
break;
case 3:
{
_localctx = new NewExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(951);
match(NEW);
setState(952);
creator();
}
break;
case 4:
{
_localctx = new CastExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(953);
match(LPAREN);
setState(954);
typeRef();
setState(955);
match(RPAREN);
setState(956);
expression(19);
}
break;
case 5:
{
_localctx = new SubExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(958);
match(LPAREN);
setState(959);
expression(0);
setState(960);
match(RPAREN);
}
break;
case 6:
{
_localctx = new PreOpExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(962);
_la = _input.LA(1);
if ( !(((((_la - 225)) & ~0x3f) == 0 && ((1L << (_la - 225)) & ((1L << (INC - 225)) | (1L << (DEC - 225)) | (1L << (ADD - 225)) | (1L << (SUB - 225)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(963);
expression(16);
}
break;
case 7:
{
_localctx = new NegExpressionContext(_localctx);
_ctx = _localctx;
_prevctx = _localctx;
setState(964);
_la = _input.LA(1);
if ( !(_la==BANG || _la==TILDE) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(965);
expression(15);
}
break;
}
_ctx.stop = _input.LT(-1);
setState(1039);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,91,_ctx);
while ( _alt!=2 && _alt!=org.antlr.v4.runtime.atn.ATN.INVALID_ALT_NUMBER ) {
if ( _alt==1 ) {
if ( _parseListeners!=null ) triggerExitRuleEvent();
_prevctx = _localctx;
{
setState(1037);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,90,_ctx) ) {
case 1:
{
_localctx = new Arth1ExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(968);
if (!(precpred(_ctx, 14))) throw new FailedPredicateException(this, "precpred(_ctx, 14)");
setState(969);
_la = _input.LA(1);
if ( !(_la==MUL || _la==DIV) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(970);
expression(15);
}
break;
case 2:
{
_localctx = new Arth2ExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(971);
if (!(precpred(_ctx, 13))) throw new FailedPredicateException(this, "precpred(_ctx, 13)");
setState(972);
_la = _input.LA(1);
if ( !(_la==ADD || _la==SUB) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(973);
expression(14);
}
break;
case 3:
{
_localctx = new BitExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(974);
if (!(precpred(_ctx, 12))) throw new FailedPredicateException(this, "precpred(_ctx, 12)");
setState(982);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,87,_ctx) ) {
case 1:
{
setState(975);
match(LT);
setState(976);
match(LT);
}
break;
case 2:
{
setState(977);
match(GT);
setState(978);
match(GT);
setState(979);
match(GT);
}
break;
case 3:
{
setState(980);
match(GT);
setState(981);
match(GT);
}
break;
}
setState(984);
expression(13);
}
break;
case 4:
{
_localctx = new CmpExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(985);
if (!(precpred(_ctx, 11))) throw new FailedPredicateException(this, "precpred(_ctx, 11)");
setState(986);
_la = _input.LA(1);
if ( !(_la==GT || _la==LT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(988);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ASSIGN) {
{
setState(987);
match(ASSIGN);
}
}
setState(990);
expression(12);
}
break;
case 5:
{
_localctx = new EqualityExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(991);
if (!(precpred(_ctx, 9))) throw new FailedPredicateException(this, "precpred(_ctx, 9)");
setState(992);
_la = _input.LA(1);
if ( !(((((_la - 217)) & ~0x3f) == 0 && ((1L << (_la - 217)) & ((1L << (EQUAL - 217)) | (1L << (TRIPLEEQUAL - 217)) | (1L << (NOTEQUAL - 217)) | (1L << (LESSANDGREATER - 217)) | (1L << (TRIPLENOTEQUAL - 217)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(993);
expression(10);
}
break;
case 6:
{
_localctx = new BitAndExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(994);
if (!(precpred(_ctx, 8))) throw new FailedPredicateException(this, "precpred(_ctx, 8)");
setState(995);
match(BITAND);
setState(996);
expression(9);
}
break;
case 7:
{
_localctx = new BitNotExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(997);
if (!(precpred(_ctx, 7))) throw new FailedPredicateException(this, "precpred(_ctx, 7)");
setState(998);
match(CARET);
setState(999);
expression(8);
}
break;
case 8:
{
_localctx = new BitOrExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1000);
if (!(precpred(_ctx, 6))) throw new FailedPredicateException(this, "precpred(_ctx, 6)");
setState(1001);
match(BITOR);
setState(1002);
expression(7);
}
break;
case 9:
{
_localctx = new LogAndExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1003);
if (!(precpred(_ctx, 5))) throw new FailedPredicateException(this, "precpred(_ctx, 5)");
setState(1004);
match(AND);
setState(1005);
expression(6);
}
break;
case 10:
{
_localctx = new LogOrExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1006);
if (!(precpred(_ctx, 4))) throw new FailedPredicateException(this, "precpred(_ctx, 4)");
setState(1007);
match(OR);
setState(1008);
expression(5);
}
break;
case 11:
{
_localctx = new CoalExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1009);
if (!(precpred(_ctx, 3))) throw new FailedPredicateException(this, "precpred(_ctx, 3)");
setState(1010);
match(COAL);
setState(1011);
expression(4);
}
break;
case 12:
{
_localctx = new CondExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1012);
if (!(precpred(_ctx, 2))) throw new FailedPredicateException(this, "precpred(_ctx, 2)");
setState(1013);
match(QUESTION);
setState(1014);
expression(0);
setState(1015);
match(COLON);
setState(1016);
expression(2);
}
break;
case 13:
{
_localctx = new AssignExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1018);
if (!(precpred(_ctx, 1))) throw new FailedPredicateException(this, "precpred(_ctx, 1)");
setState(1019);
_la = _input.LA(1);
if ( !(((((_la - 209)) & ~0x3f) == 0 && ((1L << (_la - 209)) & ((1L << (ASSIGN - 209)) | (1L << (ADD_ASSIGN - 209)) | (1L << (SUB_ASSIGN - 209)) | (1L << (MUL_ASSIGN - 209)) | (1L << (DIV_ASSIGN - 209)) | (1L << (AND_ASSIGN - 209)) | (1L << (OR_ASSIGN - 209)) | (1L << (XOR_ASSIGN - 209)) | (1L << (LSHIFT_ASSIGN - 209)) | (1L << (RSHIFT_ASSIGN - 209)) | (1L << (URSHIFT_ASSIGN - 209)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(1020);
expression(1);
}
break;
case 14:
{
_localctx = new DotExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1021);
if (!(precpred(_ctx, 23))) throw new FailedPredicateException(this, "precpred(_ctx, 23)");
setState(1022);
_la = _input.LA(1);
if ( !(_la==DOT || _la==QUESTIONDOT) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
setState(1025);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,89,_ctx) ) {
case 1:
{
setState(1023);
dotMethodCall();
}
break;
case 2:
{
setState(1024);
anyId();
}
break;
}
}
break;
case 15:
{
_localctx = new ArrayExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1027);
if (!(precpred(_ctx, 22))) throw new FailedPredicateException(this, "precpred(_ctx, 22)");
setState(1028);
match(LBRACK);
setState(1029);
expression(0);
setState(1030);
match(RBRACK);
}
break;
case 16:
{
_localctx = new PostOpExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1032);
if (!(precpred(_ctx, 17))) throw new FailedPredicateException(this, "precpred(_ctx, 17)");
setState(1033);
_la = _input.LA(1);
if ( !(_la==INC || _la==DEC) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
break;
case 17:
{
_localctx = new InstanceOfExpressionContext(new ExpressionContext(_parentctx, _parentState));
pushNewRecursionContext(_localctx, _startState, RULE_expression);
setState(1034);
if (!(precpred(_ctx, 10))) throw new FailedPredicateException(this, "precpred(_ctx, 10)");
setState(1035);
match(INSTANCEOF);
setState(1036);
typeRef();
}
break;
}
}
}
setState(1041);
_errHandler.sync(this);
_alt = getInterpreter().adaptivePredict(_input,91,_ctx);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
unrollRecursionContexts(_parentctx);
}
return _localctx;
}
public static class PrimaryContext extends ParserRuleContext {
public PrimaryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_primary; }
public PrimaryContext() { }
public void copyFrom(PrimaryContext ctx) {
super.copyFrom(ctx);
}
}
public static class ThisPrimaryContext extends PrimaryContext {
public TerminalNode THIS() { return getToken(ApexParser.THIS, 0); }
public ThisPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterThisPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitThisPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitThisPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class VoidPrimaryContext extends PrimaryContext {
public TerminalNode VOID() { return getToken(ApexParser.VOID, 0); }
public TerminalNode DOT() { return getToken(ApexParser.DOT, 0); }
public TerminalNode CLASS() { return getToken(ApexParser.CLASS, 0); }
public VoidPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterVoidPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitVoidPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitVoidPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class SoqlPrimaryContext extends PrimaryContext {
public SoqlLiteralContext soqlLiteral() {
return getRuleContext(SoqlLiteralContext.class,0);
}
public SoqlPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSoqlPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSoqlPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSoqlPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class SuperPrimaryContext extends PrimaryContext {
public TerminalNode SUPER() { return getToken(ApexParser.SUPER, 0); }
public SuperPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSuperPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSuperPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSuperPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class TypeRefPrimaryContext extends PrimaryContext {
public TypeRefContext typeRef() {
return getRuleContext(TypeRefContext.class,0);
}
public TerminalNode DOT() { return getToken(ApexParser.DOT, 0); }
public TerminalNode CLASS() { return getToken(ApexParser.CLASS, 0); }
public TypeRefPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeRefPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeRefPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeRefPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class IdPrimaryContext extends PrimaryContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public IdPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterIdPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitIdPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitIdPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class SoslPrimaryContext extends PrimaryContext {
public SoslLiteralContext soslLiteral() {
return getRuleContext(SoslLiteralContext.class,0);
}
public SoslPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSoslPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSoslPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSoslPrimary(this);
else return visitor.visitChildren(this);
}
}
public static class LiteralPrimaryContext extends PrimaryContext {
public LiteralContext literal() {
return getRuleContext(LiteralContext.class,0);
}
public LiteralPrimaryContext(PrimaryContext ctx) { copyFrom(ctx); }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLiteralPrimary(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLiteralPrimary(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLiteralPrimary(this);
else return visitor.visitChildren(this);
}
}
public final PrimaryContext primary() throws RecognitionException {
PrimaryContext _localctx = new PrimaryContext(_ctx, getState());
enterRule(_localctx, 154, RULE_primary);
try {
setState(1055);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,92,_ctx) ) {
case 1:
_localctx = new ThisPrimaryContext(_localctx);
enterOuterAlt(_localctx, 1);
{
setState(1042);
match(THIS);
}
break;
case 2:
_localctx = new SuperPrimaryContext(_localctx);
enterOuterAlt(_localctx, 2);
{
setState(1043);
match(SUPER);
}
break;
case 3:
_localctx = new LiteralPrimaryContext(_localctx);
enterOuterAlt(_localctx, 3);
{
setState(1044);
literal();
}
break;
case 4:
_localctx = new TypeRefPrimaryContext(_localctx);
enterOuterAlt(_localctx, 4);
{
setState(1045);
typeRef();
setState(1046);
match(DOT);
setState(1047);
match(CLASS);
}
break;
case 5:
_localctx = new VoidPrimaryContext(_localctx);
enterOuterAlt(_localctx, 5);
{
setState(1049);
match(VOID);
setState(1050);
match(DOT);
setState(1051);
match(CLASS);
}
break;
case 6:
_localctx = new IdPrimaryContext(_localctx);
enterOuterAlt(_localctx, 6);
{
setState(1052);
id();
}
break;
case 7:
_localctx = new SoqlPrimaryContext(_localctx);
enterOuterAlt(_localctx, 7);
{
setState(1053);
soqlLiteral();
}
break;
case 8:
_localctx = new SoslPrimaryContext(_localctx);
enterOuterAlt(_localctx, 8);
{
setState(1054);
soslLiteral();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MethodCallContext extends ParserRuleContext {
public IdContext id() {
return getRuleContext(IdContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public TerminalNode THIS() { return getToken(ApexParser.THIS, 0); }
public TerminalNode SUPER() { return getToken(ApexParser.SUPER, 0); }
public MethodCallContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_methodCall; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMethodCall(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMethodCall(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMethodCall(this);
else return visitor.visitChildren(this);
}
}
public final MethodCallContext methodCall() throws RecognitionException {
MethodCallContext _localctx = new MethodCallContext(_ctx, getState());
enterRule(_localctx, 156, RULE_methodCall);
int _la;
try {
setState(1076);
_errHandler.sync(this);
switch (_input.LA(1)) {
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case SET:
case SHARING:
case SWITCH:
case TRANSIENT:
case TRIGGER:
case WHEN:
case WITH:
case WITHOUT:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case Identifier:
enterOuterAlt(_localctx, 1);
{
setState(1057);
id();
setState(1058);
match(LPAREN);
setState(1060);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(1059);
expressionList();
}
}
setState(1062);
match(RPAREN);
}
break;
case THIS:
enterOuterAlt(_localctx, 2);
{
setState(1064);
match(THIS);
setState(1065);
match(LPAREN);
setState(1067);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(1066);
expressionList();
}
}
setState(1069);
match(RPAREN);
}
break;
case SUPER:
enterOuterAlt(_localctx, 3);
{
setState(1070);
match(SUPER);
setState(1071);
match(LPAREN);
setState(1073);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(1072);
expressionList();
}
}
setState(1075);
match(RPAREN);
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DotMethodCallContext extends ParserRuleContext {
public AnyIdContext anyId() {
return getRuleContext(AnyIdContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public DotMethodCallContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dotMethodCall; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDotMethodCall(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDotMethodCall(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDotMethodCall(this);
else return visitor.visitChildren(this);
}
}
public final DotMethodCallContext dotMethodCall() throws RecognitionException {
DotMethodCallContext _localctx = new DotMethodCallContext(_ctx, getState());
enterRule(_localctx, 158, RULE_dotMethodCall);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1078);
anyId();
setState(1079);
match(LPAREN);
setState(1081);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(1080);
expressionList();
}
}
setState(1083);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CreatorContext extends ParserRuleContext {
public CreatedNameContext createdName() {
return getRuleContext(CreatedNameContext.class,0);
}
public NoRestContext noRest() {
return getRuleContext(NoRestContext.class,0);
}
public ClassCreatorRestContext classCreatorRest() {
return getRuleContext(ClassCreatorRestContext.class,0);
}
public ArrayCreatorRestContext arrayCreatorRest() {
return getRuleContext(ArrayCreatorRestContext.class,0);
}
public MapCreatorRestContext mapCreatorRest() {
return getRuleContext(MapCreatorRestContext.class,0);
}
public SetCreatorRestContext setCreatorRest() {
return getRuleContext(SetCreatorRestContext.class,0);
}
public CreatorContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_creator; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCreator(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCreator(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCreator(this);
else return visitor.visitChildren(this);
}
}
public final CreatorContext creator() throws RecognitionException {
CreatorContext _localctx = new CreatorContext(_ctx, getState());
enterRule(_localctx, 160, RULE_creator);
try {
enterOuterAlt(_localctx, 1);
{
setState(1085);
createdName();
setState(1091);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,98,_ctx) ) {
case 1:
{
setState(1086);
noRest();
}
break;
case 2:
{
setState(1087);
classCreatorRest();
}
break;
case 3:
{
setState(1088);
arrayCreatorRest();
}
break;
case 4:
{
setState(1089);
mapCreatorRest();
}
break;
case 5:
{
setState(1090);
setCreatorRest();
}
break;
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CreatedNameContext extends ParserRuleContext {
public List idCreatedNamePair() {
return getRuleContexts(IdCreatedNamePairContext.class);
}
public IdCreatedNamePairContext idCreatedNamePair(int i) {
return getRuleContext(IdCreatedNamePairContext.class,i);
}
public List DOT() { return getTokens(ApexParser.DOT); }
public TerminalNode DOT(int i) {
return getToken(ApexParser.DOT, i);
}
public CreatedNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_createdName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCreatedName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCreatedName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCreatedName(this);
else return visitor.visitChildren(this);
}
}
public final CreatedNameContext createdName() throws RecognitionException {
CreatedNameContext _localctx = new CreatedNameContext(_ctx, getState());
enterRule(_localctx, 162, RULE_createdName);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1093);
idCreatedNamePair();
setState(1098);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==DOT) {
{
{
setState(1094);
match(DOT);
setState(1095);
idCreatedNamePair();
}
}
setState(1100);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class IdCreatedNamePairContext extends ParserRuleContext {
public AnyIdContext anyId() {
return getRuleContext(AnyIdContext.class,0);
}
public TerminalNode LT() { return getToken(ApexParser.LT, 0); }
public TypeListContext typeList() {
return getRuleContext(TypeListContext.class,0);
}
public TerminalNode GT() { return getToken(ApexParser.GT, 0); }
public IdCreatedNamePairContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_idCreatedNamePair; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterIdCreatedNamePair(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitIdCreatedNamePair(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitIdCreatedNamePair(this);
else return visitor.visitChildren(this);
}
}
public final IdCreatedNamePairContext idCreatedNamePair() throws RecognitionException {
IdCreatedNamePairContext _localctx = new IdCreatedNamePairContext(_ctx, getState());
enterRule(_localctx, 164, RULE_idCreatedNamePair);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1101);
anyId();
setState(1106);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==LT) {
{
setState(1102);
match(LT);
setState(1103);
typeList();
setState(1104);
match(GT);
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class NoRestContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public NoRestContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_noRest; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterNoRest(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitNoRest(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitNoRest(this);
else return visitor.visitChildren(this);
}
}
public final NoRestContext noRest() throws RecognitionException {
NoRestContext _localctx = new NoRestContext(_ctx, getState());
enterRule(_localctx, 166, RULE_noRest);
try {
enterOuterAlt(_localctx, 1);
{
setState(1108);
match(LBRACE);
setState(1109);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ClassCreatorRestContext extends ParserRuleContext {
public ArgumentsContext arguments() {
return getRuleContext(ArgumentsContext.class,0);
}
public ClassCreatorRestContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_classCreatorRest; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterClassCreatorRest(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitClassCreatorRest(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitClassCreatorRest(this);
else return visitor.visitChildren(this);
}
}
public final ClassCreatorRestContext classCreatorRest() throws RecognitionException {
ClassCreatorRestContext _localctx = new ClassCreatorRestContext(_ctx, getState());
enterRule(_localctx, 168, RULE_classCreatorRest);
try {
enterOuterAlt(_localctx, 1);
{
setState(1111);
arguments();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArrayCreatorRestContext extends ParserRuleContext {
public TerminalNode LBRACK() { return getToken(ApexParser.LBRACK, 0); }
public ExpressionContext expression() {
return getRuleContext(ExpressionContext.class,0);
}
public TerminalNode RBRACK() { return getToken(ApexParser.RBRACK, 0); }
public ArrayInitializerContext arrayInitializer() {
return getRuleContext(ArrayInitializerContext.class,0);
}
public ArrayCreatorRestContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_arrayCreatorRest; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArrayCreatorRest(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArrayCreatorRest(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArrayCreatorRest(this);
else return visitor.visitChildren(this);
}
}
public final ArrayCreatorRestContext arrayCreatorRest() throws RecognitionException {
ArrayCreatorRestContext _localctx = new ArrayCreatorRestContext(_ctx, getState());
enterRule(_localctx, 170, RULE_arrayCreatorRest);
try {
setState(1122);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,102,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1113);
match(LBRACK);
setState(1114);
expression(0);
setState(1115);
match(RBRACK);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1117);
match(LBRACK);
setState(1118);
match(RBRACK);
setState(1120);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,101,_ctx) ) {
case 1:
{
setState(1119);
arrayInitializer();
}
break;
}
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MapCreatorRestContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public List mapCreatorRestPair() {
return getRuleContexts(MapCreatorRestPairContext.class);
}
public MapCreatorRestPairContext mapCreatorRestPair(int i) {
return getRuleContext(MapCreatorRestPairContext.class,i);
}
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public MapCreatorRestContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_mapCreatorRest; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMapCreatorRest(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMapCreatorRest(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMapCreatorRest(this);
else return visitor.visitChildren(this);
}
}
public final MapCreatorRestContext mapCreatorRest() throws RecognitionException {
MapCreatorRestContext _localctx = new MapCreatorRestContext(_ctx, getState());
enterRule(_localctx, 172, RULE_mapCreatorRest);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1124);
match(LBRACE);
setState(1125);
mapCreatorRestPair();
setState(1130);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1126);
match(COMMA);
setState(1127);
mapCreatorRestPair();
}
}
setState(1132);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1133);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class MapCreatorRestPairContext extends ParserRuleContext {
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode MAPTO() { return getToken(ApexParser.MAPTO, 0); }
public MapCreatorRestPairContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_mapCreatorRestPair; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterMapCreatorRestPair(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitMapCreatorRestPair(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitMapCreatorRestPair(this);
else return visitor.visitChildren(this);
}
}
public final MapCreatorRestPairContext mapCreatorRestPair() throws RecognitionException {
MapCreatorRestPairContext _localctx = new MapCreatorRestPairContext(_ctx, getState());
enterRule(_localctx, 174, RULE_mapCreatorRestPair);
try {
enterOuterAlt(_localctx, 1);
{
setState(1135);
expression(0);
setState(1136);
match(MAPTO);
setState(1137);
expression(0);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SetCreatorRestContext extends ParserRuleContext {
public TerminalNode LBRACE() { return getToken(ApexParser.LBRACE, 0); }
public List expression() {
return getRuleContexts(ExpressionContext.class);
}
public ExpressionContext expression(int i) {
return getRuleContext(ExpressionContext.class,i);
}
public TerminalNode RBRACE() { return getToken(ApexParser.RBRACE, 0); }
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public SetCreatorRestContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_setCreatorRest; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSetCreatorRest(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSetCreatorRest(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSetCreatorRest(this);
else return visitor.visitChildren(this);
}
}
public final SetCreatorRestContext setCreatorRest() throws RecognitionException {
SetCreatorRestContext _localctx = new SetCreatorRestContext(_ctx, getState());
enterRule(_localctx, 176, RULE_setCreatorRest);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1139);
match(LBRACE);
setState(1140);
expression(0);
setState(1145);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1141);
match(COMMA);
{
setState(1142);
expression(0);
}
}
}
setState(1147);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1148);
match(RBRACE);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ArgumentsContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ExpressionListContext expressionList() {
return getRuleContext(ExpressionListContext.class,0);
}
public ArgumentsContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_arguments; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterArguments(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitArguments(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitArguments(this);
else return visitor.visitChildren(this);
}
}
public final ArgumentsContext arguments() throws RecognitionException {
ArgumentsContext _localctx = new ArgumentsContext(_ctx, getState());
enterRule(_localctx, 178, RULE_arguments);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1150);
match(LPAREN);
setState(1152);
_errHandler.sync(this);
_la = _input.LA(1);
if ((((_la) & ~0x3f) == 0 && ((1L << _la) & ((1L << AFTER) | (1L << BEFORE) | (1L << GET) | (1L << INHERITED) | (1L << INSTANCEOF) | (1L << NEW) | (1L << NULL) | (1L << SET) | (1L << SHARING) | (1L << SUPER) | (1L << SWITCH) | (1L << THIS) | (1L << TRANSIENT) | (1L << TRIGGER) | (1L << VOID) | (1L << WHEN) | (1L << WITH) | (1L << WITHOUT) | (1L << LIST) | (1L << MAP) | (1L << SYSTEM) | (1L << USER) | (1L << SELECT) | (1L << COUNT) | (1L << FROM) | (1L << AS) | (1L << USING))) != 0) || ((((_la - 64)) & ~0x3f) == 0 && ((1L << (_la - 64)) & ((1L << (SCOPE - 64)) | (1L << (WHERE - 64)) | (1L << (ORDER - 64)) | (1L << (BY - 64)) | (1L << (LIMIT - 64)) | (1L << (SOQLAND - 64)) | (1L << (SOQLOR - 64)) | (1L << (NOT - 64)) | (1L << (AVG - 64)) | (1L << (COUNT_DISTINCT - 64)) | (1L << (MIN - 64)) | (1L << (MAX - 64)) | (1L << (SUM - 64)) | (1L << (TYPEOF - 64)) | (1L << (END - 64)) | (1L << (THEN - 64)) | (1L << (LIKE - 64)) | (1L << (IN - 64)) | (1L << (INCLUDES - 64)) | (1L << (EXCLUDES - 64)) | (1L << (ASC - 64)) | (1L << (DESC - 64)) | (1L << (NULLS - 64)) | (1L << (FIRST - 64)) | (1L << (LAST - 64)) | (1L << (GROUP - 64)) | (1L << (ALL - 64)) | (1L << (ROWS - 64)) | (1L << (VIEW - 64)) | (1L << (HAVING - 64)) | (1L << (ROLLUP - 64)) | (1L << (TOLABEL - 64)) | (1L << (OFFSET - 64)) | (1L << (DATA - 64)) | (1L << (CATEGORY - 64)) | (1L << (AT - 64)) | (1L << (ABOVE - 64)) | (1L << (BELOW - 64)) | (1L << (ABOVE_OR_BELOW - 64)) | (1L << (SECURITY_ENFORCED - 64)) | (1L << (SYSTEM_MODE - 64)) | (1L << (USER_MODE - 64)) | (1L << (REFERENCE - 64)) | (1L << (CUBE - 64)) | (1L << (FORMAT - 64)) | (1L << (TRACKING - 64)) | (1L << (VIEWSTAT - 64)) | (1L << (CUSTOM - 64)) | (1L << (STANDARD - 64)) | (1L << (DISTANCE - 64)) | (1L << (GEOLOCATION - 64)) | (1L << (GROUPING - 64)) | (1L << (CONVERT_CURRENCY - 64)) | (1L << (CALENDAR_MONTH - 64)) | (1L << (CALENDAR_QUARTER - 64)) | (1L << (CALENDAR_YEAR - 64)) | (1L << (DAY_IN_MONTH - 64)) | (1L << (DAY_IN_WEEK - 64)) | (1L << (DAY_IN_YEAR - 64)) | (1L << (DAY_ONLY - 64)) | (1L << (FISCAL_MONTH - 64)) | (1L << (FISCAL_QUARTER - 64)) | (1L << (FISCAL_YEAR - 64)) | (1L << (HOUR_IN_DAY - 64)))) != 0) || ((((_la - 128)) & ~0x3f) == 0 && ((1L << (_la - 128)) & ((1L << (WEEK_IN_MONTH - 128)) | (1L << (WEEK_IN_YEAR - 128)) | (1L << (CONVERT_TIMEZONE - 128)) | (1L << (YESTERDAY - 128)) | (1L << (TODAY - 128)) | (1L << (TOMORROW - 128)) | (1L << (LAST_WEEK - 128)) | (1L << (THIS_WEEK - 128)) | (1L << (NEXT_WEEK - 128)) | (1L << (LAST_MONTH - 128)) | (1L << (THIS_MONTH - 128)) | (1L << (NEXT_MONTH - 128)) | (1L << (LAST_90_DAYS - 128)) | (1L << (NEXT_90_DAYS - 128)) | (1L << (LAST_N_DAYS_N - 128)) | (1L << (NEXT_N_DAYS_N - 128)) | (1L << (N_DAYS_AGO_N - 128)) | (1L << (NEXT_N_WEEKS_N - 128)) | (1L << (LAST_N_WEEKS_N - 128)) | (1L << (N_WEEKS_AGO_N - 128)) | (1L << (NEXT_N_MONTHS_N - 128)) | (1L << (LAST_N_MONTHS_N - 128)) | (1L << (N_MONTHS_AGO_N - 128)) | (1L << (THIS_QUARTER - 128)) | (1L << (LAST_QUARTER - 128)) | (1L << (NEXT_QUARTER - 128)) | (1L << (NEXT_N_QUARTERS_N - 128)) | (1L << (LAST_N_QUARTERS_N - 128)) | (1L << (N_QUARTERS_AGO_N - 128)) | (1L << (THIS_YEAR - 128)) | (1L << (LAST_YEAR - 128)) | (1L << (NEXT_YEAR - 128)) | (1L << (NEXT_N_YEARS_N - 128)) | (1L << (LAST_N_YEARS_N - 128)) | (1L << (N_YEARS_AGO_N - 128)) | (1L << (THIS_FISCAL_QUARTER - 128)) | (1L << (LAST_FISCAL_QUARTER - 128)) | (1L << (NEXT_FISCAL_QUARTER - 128)) | (1L << (NEXT_N_FISCAL_QUARTERS_N - 128)) | (1L << (LAST_N_FISCAL_QUARTERS_N - 128)) | (1L << (N_FISCAL_QUARTERS_AGO_N - 128)) | (1L << (THIS_FISCAL_YEAR - 128)) | (1L << (LAST_FISCAL_YEAR - 128)) | (1L << (NEXT_FISCAL_YEAR - 128)) | (1L << (NEXT_N_FISCAL_YEARS_N - 128)) | (1L << (LAST_N_FISCAL_YEARS_N - 128)) | (1L << (N_FISCAL_YEARS_AGO_N - 128)) | (1L << (IntegralCurrencyLiteral - 128)) | (1L << (FIND - 128)) | (1L << (EMAIL - 128)) | (1L << (NAME - 128)) | (1L << (PHONE - 128)) | (1L << (SIDEBAR - 128)) | (1L << (FIELDS - 128)) | (1L << (METADATA - 128)) | (1L << (PRICEBOOKID - 128)) | (1L << (NETWORK - 128)) | (1L << (SNIPPET - 128)) | (1L << (TARGET_LENGTH - 128)) | (1L << (DIVISION - 128)) | (1L << (RETURNING - 128)) | (1L << (LISTVIEW - 128)))) != 0) || ((((_la - 192)) & ~0x3f) == 0 && ((1L << (_la - 192)) & ((1L << (FindLiteral - 192)) | (1L << (IntegerLiteral - 192)) | (1L << (LongLiteral - 192)) | (1L << (NumberLiteral - 192)) | (1L << (BooleanLiteral - 192)) | (1L << (StringLiteral - 192)) | (1L << (LPAREN - 192)) | (1L << (LBRACK - 192)) | (1L << (BANG - 192)) | (1L << (TILDE - 192)) | (1L << (INC - 192)) | (1L << (DEC - 192)) | (1L << (ADD - 192)) | (1L << (SUB - 192)) | (1L << (Identifier - 192)))) != 0)) {
{
setState(1151);
expressionList();
}
}
setState(1154);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SoqlLiteralContext extends ParserRuleContext {
public TerminalNode LBRACK() { return getToken(ApexParser.LBRACK, 0); }
public QueryContext query() {
return getRuleContext(QueryContext.class,0);
}
public TerminalNode RBRACK() { return getToken(ApexParser.RBRACK, 0); }
public SoqlLiteralContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_soqlLiteral; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSoqlLiteral(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSoqlLiteral(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSoqlLiteral(this);
else return visitor.visitChildren(this);
}
}
public final SoqlLiteralContext soqlLiteral() throws RecognitionException {
SoqlLiteralContext _localctx = new SoqlLiteralContext(_ctx, getState());
enterRule(_localctx, 180, RULE_soqlLiteral);
try {
enterOuterAlt(_localctx, 1);
{
setState(1156);
match(LBRACK);
setState(1157);
query();
setState(1158);
match(RBRACK);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class QueryContext extends ParserRuleContext {
public TerminalNode SELECT() { return getToken(ApexParser.SELECT, 0); }
public SelectListContext selectList() {
return getRuleContext(SelectListContext.class,0);
}
public TerminalNode FROM() { return getToken(ApexParser.FROM, 0); }
public FromNameListContext fromNameList() {
return getRuleContext(FromNameListContext.class,0);
}
public ForClausesContext forClauses() {
return getRuleContext(ForClausesContext.class,0);
}
public UsingScopeContext usingScope() {
return getRuleContext(UsingScopeContext.class,0);
}
public WhereClauseContext whereClause() {
return getRuleContext(WhereClauseContext.class,0);
}
public WithClauseContext withClause() {
return getRuleContext(WithClauseContext.class,0);
}
public GroupByClauseContext groupByClause() {
return getRuleContext(GroupByClauseContext.class,0);
}
public OrderByClauseContext orderByClause() {
return getRuleContext(OrderByClauseContext.class,0);
}
public LimitClauseContext limitClause() {
return getRuleContext(LimitClauseContext.class,0);
}
public OffsetClauseContext offsetClause() {
return getRuleContext(OffsetClauseContext.class,0);
}
public AllRowsClauseContext allRowsClause() {
return getRuleContext(AllRowsClauseContext.class,0);
}
public TerminalNode UPDATE() { return getToken(ApexParser.UPDATE, 0); }
public UpdateListContext updateList() {
return getRuleContext(UpdateListContext.class,0);
}
public QueryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_query; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterQuery(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitQuery(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitQuery(this);
else return visitor.visitChildren(this);
}
}
public final QueryContext query() throws RecognitionException {
QueryContext _localctx = new QueryContext(_ctx, getState());
enterRule(_localctx, 182, RULE_query);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1160);
match(SELECT);
setState(1161);
selectList();
setState(1162);
match(FROM);
setState(1163);
fromNameList();
setState(1165);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==USING) {
{
setState(1164);
usingScope();
}
}
setState(1168);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==WHERE) {
{
setState(1167);
whereClause();
}
}
setState(1171);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==WITH) {
{
setState(1170);
withClause();
}
}
setState(1174);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==GROUP) {
{
setState(1173);
groupByClause();
}
}
setState(1177);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ORDER) {
{
setState(1176);
orderByClause();
}
}
setState(1180);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==LIMIT) {
{
setState(1179);
limitClause();
}
}
setState(1183);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==OFFSET) {
{
setState(1182);
offsetClause();
}
}
setState(1186);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ALL) {
{
setState(1185);
allRowsClause();
}
}
setState(1188);
forClauses();
setState(1191);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==UPDATE) {
{
setState(1189);
match(UPDATE);
setState(1190);
updateList();
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SubQueryContext extends ParserRuleContext {
public TerminalNode SELECT() { return getToken(ApexParser.SELECT, 0); }
public SubFieldListContext subFieldList() {
return getRuleContext(SubFieldListContext.class,0);
}
public TerminalNode FROM() { return getToken(ApexParser.FROM, 0); }
public FromNameListContext fromNameList() {
return getRuleContext(FromNameListContext.class,0);
}
public ForClausesContext forClauses() {
return getRuleContext(ForClausesContext.class,0);
}
public WhereClauseContext whereClause() {
return getRuleContext(WhereClauseContext.class,0);
}
public OrderByClauseContext orderByClause() {
return getRuleContext(OrderByClauseContext.class,0);
}
public LimitClauseContext limitClause() {
return getRuleContext(LimitClauseContext.class,0);
}
public TerminalNode UPDATE() { return getToken(ApexParser.UPDATE, 0); }
public UpdateListContext updateList() {
return getRuleContext(UpdateListContext.class,0);
}
public SubQueryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_subQuery; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSubQuery(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSubQuery(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSubQuery(this);
else return visitor.visitChildren(this);
}
}
public final SubQueryContext subQuery() throws RecognitionException {
SubQueryContext _localctx = new SubQueryContext(_ctx, getState());
enterRule(_localctx, 184, RULE_subQuery);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1193);
match(SELECT);
setState(1194);
subFieldList();
setState(1195);
match(FROM);
setState(1196);
fromNameList();
setState(1198);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==WHERE) {
{
setState(1197);
whereClause();
}
}
setState(1201);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ORDER) {
{
setState(1200);
orderByClause();
}
}
setState(1204);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==LIMIT) {
{
setState(1203);
limitClause();
}
}
setState(1206);
forClauses();
setState(1209);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==UPDATE) {
{
setState(1207);
match(UPDATE);
setState(1208);
updateList();
}
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SelectListContext extends ParserRuleContext {
public List selectEntry() {
return getRuleContexts(SelectEntryContext.class);
}
public SelectEntryContext selectEntry(int i) {
return getRuleContext(SelectEntryContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public SelectListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_selectList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSelectList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSelectList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSelectList(this);
else return visitor.visitChildren(this);
}
}
public final SelectListContext selectList() throws RecognitionException {
SelectListContext _localctx = new SelectListContext(_ctx, getState());
enterRule(_localctx, 186, RULE_selectList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1211);
selectEntry();
setState(1216);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1212);
match(COMMA);
setState(1213);
selectEntry();
}
}
setState(1218);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SelectEntryContext extends ParserRuleContext {
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public SoqlIdContext soqlId() {
return getRuleContext(SoqlIdContext.class,0);
}
public SoqlFunctionContext soqlFunction() {
return getRuleContext(SoqlFunctionContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public SubQueryContext subQuery() {
return getRuleContext(SubQueryContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public TypeOfContext typeOf() {
return getRuleContext(TypeOfContext.class,0);
}
public SelectEntryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_selectEntry; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSelectEntry(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSelectEntry(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSelectEntry(this);
else return visitor.visitChildren(this);
}
}
public final SelectEntryContext selectEntry() throws RecognitionException {
SelectEntryContext _localctx = new SelectEntryContext(_ctx, getState());
enterRule(_localctx, 188, RULE_selectEntry);
try {
setState(1234);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,123,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1219);
fieldName();
setState(1221);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,120,_ctx) ) {
case 1:
{
setState(1220);
soqlId();
}
break;
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1223);
soqlFunction();
setState(1225);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,121,_ctx) ) {
case 1:
{
setState(1224);
soqlId();
}
break;
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1227);
match(LPAREN);
setState(1228);
subQuery();
setState(1229);
match(RPAREN);
setState(1231);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,122,_ctx) ) {
case 1:
{
setState(1230);
soqlId();
}
break;
}
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1233);
typeOf();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FieldNameContext extends ParserRuleContext {
public List soqlId() {
return getRuleContexts(SoqlIdContext.class);
}
public SoqlIdContext soqlId(int i) {
return getRuleContext(SoqlIdContext.class,i);
}
public List DOT() { return getTokens(ApexParser.DOT); }
public TerminalNode DOT(int i) {
return getToken(ApexParser.DOT, i);
}
public FieldNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fieldName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFieldName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFieldName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFieldName(this);
else return visitor.visitChildren(this);
}
}
public final FieldNameContext fieldName() throws RecognitionException {
FieldNameContext _localctx = new FieldNameContext(_ctx, getState());
enterRule(_localctx, 190, RULE_fieldName);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1236);
soqlId();
setState(1241);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==DOT) {
{
{
setState(1237);
match(DOT);
setState(1238);
soqlId();
}
}
setState(1243);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FromNameListContext extends ParserRuleContext {
public List fieldName() {
return getRuleContexts(FieldNameContext.class);
}
public FieldNameContext fieldName(int i) {
return getRuleContext(FieldNameContext.class,i);
}
public List soqlId() {
return getRuleContexts(SoqlIdContext.class);
}
public SoqlIdContext soqlId(int i) {
return getRuleContext(SoqlIdContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public FromNameListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fromNameList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFromNameList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFromNameList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFromNameList(this);
else return visitor.visitChildren(this);
}
}
public final FromNameListContext fromNameList() throws RecognitionException {
FromNameListContext _localctx = new FromNameListContext(_ctx, getState());
enterRule(_localctx, 192, RULE_fromNameList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1244);
fieldName();
setState(1246);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,125,_ctx) ) {
case 1:
{
setState(1245);
soqlId();
}
break;
}
setState(1255);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1248);
match(COMMA);
setState(1249);
fieldName();
setState(1251);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,126,_ctx) ) {
case 1:
{
setState(1250);
soqlId();
}
break;
}
}
}
setState(1257);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SubFieldListContext extends ParserRuleContext {
public List subFieldEntry() {
return getRuleContexts(SubFieldEntryContext.class);
}
public SubFieldEntryContext subFieldEntry(int i) {
return getRuleContext(SubFieldEntryContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public SubFieldListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_subFieldList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSubFieldList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSubFieldList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSubFieldList(this);
else return visitor.visitChildren(this);
}
}
public final SubFieldListContext subFieldList() throws RecognitionException {
SubFieldListContext _localctx = new SubFieldListContext(_ctx, getState());
enterRule(_localctx, 194, RULE_subFieldList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1258);
subFieldEntry();
setState(1263);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1259);
match(COMMA);
setState(1260);
subFieldEntry();
}
}
setState(1265);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SubFieldEntryContext extends ParserRuleContext {
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public SoqlIdContext soqlId() {
return getRuleContext(SoqlIdContext.class,0);
}
public SoqlFunctionContext soqlFunction() {
return getRuleContext(SoqlFunctionContext.class,0);
}
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public SubQueryContext subQuery() {
return getRuleContext(SubQueryContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public TypeOfContext typeOf() {
return getRuleContext(TypeOfContext.class,0);
}
public SubFieldEntryContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_subFieldEntry; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSubFieldEntry(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSubFieldEntry(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSubFieldEntry(this);
else return visitor.visitChildren(this);
}
}
public final SubFieldEntryContext subFieldEntry() throws RecognitionException {
SubFieldEntryContext _localctx = new SubFieldEntryContext(_ctx, getState());
enterRule(_localctx, 196, RULE_subFieldEntry);
try {
setState(1281);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,132,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1266);
fieldName();
setState(1268);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,129,_ctx) ) {
case 1:
{
setState(1267);
soqlId();
}
break;
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1270);
soqlFunction();
setState(1272);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,130,_ctx) ) {
case 1:
{
setState(1271);
soqlId();
}
break;
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1274);
match(LPAREN);
setState(1275);
subQuery();
setState(1276);
match(RPAREN);
setState(1278);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,131,_ctx) ) {
case 1:
{
setState(1277);
soqlId();
}
break;
}
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1280);
typeOf();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SoqlFieldsParameterContext extends ParserRuleContext {
public TerminalNode ALL() { return getToken(ApexParser.ALL, 0); }
public TerminalNode CUSTOM() { return getToken(ApexParser.CUSTOM, 0); }
public TerminalNode STANDARD() { return getToken(ApexParser.STANDARD, 0); }
public SoqlFieldsParameterContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_soqlFieldsParameter; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSoqlFieldsParameter(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSoqlFieldsParameter(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSoqlFieldsParameter(this);
else return visitor.visitChildren(this);
}
}
public final SoqlFieldsParameterContext soqlFieldsParameter() throws RecognitionException {
SoqlFieldsParameterContext _localctx = new SoqlFieldsParameterContext(_ctx, getState());
enterRule(_localctx, 198, RULE_soqlFieldsParameter);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1283);
_la = _input.LA(1);
if ( !(((((_la - 90)) & ~0x3f) == 0 && ((1L << (_la - 90)) & ((1L << (ALL - 90)) | (1L << (CUSTOM - 90)) | (1L << (STANDARD - 90)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SoqlFunctionContext extends ParserRuleContext {
public TerminalNode AVG() { return getToken(ApexParser.AVG, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public TerminalNode COUNT() { return getToken(ApexParser.COUNT, 0); }
public TerminalNode COUNT_DISTINCT() { return getToken(ApexParser.COUNT_DISTINCT, 0); }
public TerminalNode MIN() { return getToken(ApexParser.MIN, 0); }
public TerminalNode MAX() { return getToken(ApexParser.MAX, 0); }
public TerminalNode SUM() { return getToken(ApexParser.SUM, 0); }
public TerminalNode TOLABEL() { return getToken(ApexParser.TOLABEL, 0); }
public TerminalNode FORMAT() { return getToken(ApexParser.FORMAT, 0); }
public SoqlFunctionContext soqlFunction() {
return getRuleContext(SoqlFunctionContext.class,0);
}
public TerminalNode CALENDAR_MONTH() { return getToken(ApexParser.CALENDAR_MONTH, 0); }
public DateFieldNameContext dateFieldName() {
return getRuleContext(DateFieldNameContext.class,0);
}
public TerminalNode CALENDAR_QUARTER() { return getToken(ApexParser.CALENDAR_QUARTER, 0); }
public TerminalNode CALENDAR_YEAR() { return getToken(ApexParser.CALENDAR_YEAR, 0); }
public TerminalNode DAY_IN_MONTH() { return getToken(ApexParser.DAY_IN_MONTH, 0); }
public TerminalNode DAY_IN_WEEK() { return getToken(ApexParser.DAY_IN_WEEK, 0); }
public TerminalNode DAY_IN_YEAR() { return getToken(ApexParser.DAY_IN_YEAR, 0); }
public TerminalNode DAY_ONLY() { return getToken(ApexParser.DAY_ONLY, 0); }
public TerminalNode FISCAL_MONTH() { return getToken(ApexParser.FISCAL_MONTH, 0); }
public TerminalNode FISCAL_QUARTER() { return getToken(ApexParser.FISCAL_QUARTER, 0); }
public TerminalNode FISCAL_YEAR() { return getToken(ApexParser.FISCAL_YEAR, 0); }
public TerminalNode HOUR_IN_DAY() { return getToken(ApexParser.HOUR_IN_DAY, 0); }
public TerminalNode WEEK_IN_MONTH() { return getToken(ApexParser.WEEK_IN_MONTH, 0); }
public TerminalNode WEEK_IN_YEAR() { return getToken(ApexParser.WEEK_IN_YEAR, 0); }
public TerminalNode FIELDS() { return getToken(ApexParser.FIELDS, 0); }
public SoqlFieldsParameterContext soqlFieldsParameter() {
return getRuleContext(SoqlFieldsParameterContext.class,0);
}
public TerminalNode DISTANCE() { return getToken(ApexParser.DISTANCE, 0); }
public List locationValue() {
return getRuleContexts(LocationValueContext.class);
}
public LocationValueContext locationValue(int i) {
return getRuleContext(LocationValueContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public TerminalNode StringLiteral() { return getToken(ApexParser.StringLiteral, 0); }
public TerminalNode GROUPING() { return getToken(ApexParser.GROUPING, 0); }
public TerminalNode CONVERT_CURRENCY() { return getToken(ApexParser.CONVERT_CURRENCY, 0); }
public SoqlFunctionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_soqlFunction; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSoqlFunction(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSoqlFunction(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSoqlFunction(this);
else return visitor.visitChildren(this);
}
}
public final SoqlFunctionContext soqlFunction() throws RecognitionException {
SoqlFunctionContext _localctx = new SoqlFunctionContext(_ctx, getState());
enterRule(_localctx, 200, RULE_soqlFunction);
try {
setState(1420);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,134,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1285);
match(AVG);
setState(1286);
match(LPAREN);
setState(1287);
fieldName();
setState(1288);
match(RPAREN);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1290);
match(COUNT);
setState(1291);
match(LPAREN);
setState(1292);
match(RPAREN);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1293);
match(COUNT);
setState(1294);
match(LPAREN);
setState(1295);
fieldName();
setState(1296);
match(RPAREN);
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1298);
match(COUNT_DISTINCT);
setState(1299);
match(LPAREN);
setState(1300);
fieldName();
setState(1301);
match(RPAREN);
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(1303);
match(MIN);
setState(1304);
match(LPAREN);
setState(1305);
fieldName();
setState(1306);
match(RPAREN);
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(1308);
match(MAX);
setState(1309);
match(LPAREN);
setState(1310);
fieldName();
setState(1311);
match(RPAREN);
}
break;
case 7:
enterOuterAlt(_localctx, 7);
{
setState(1313);
match(SUM);
setState(1314);
match(LPAREN);
setState(1315);
fieldName();
setState(1316);
match(RPAREN);
}
break;
case 8:
enterOuterAlt(_localctx, 8);
{
setState(1318);
match(TOLABEL);
setState(1319);
match(LPAREN);
setState(1320);
fieldName();
setState(1321);
match(RPAREN);
}
break;
case 9:
enterOuterAlt(_localctx, 9);
{
setState(1323);
match(FORMAT);
setState(1324);
match(LPAREN);
setState(1327);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,133,_ctx) ) {
case 1:
{
setState(1325);
fieldName();
}
break;
case 2:
{
setState(1326);
soqlFunction();
}
break;
}
setState(1329);
match(RPAREN);
}
break;
case 10:
enterOuterAlt(_localctx, 10);
{
setState(1331);
match(CALENDAR_MONTH);
setState(1332);
match(LPAREN);
setState(1333);
dateFieldName();
setState(1334);
match(RPAREN);
}
break;
case 11:
enterOuterAlt(_localctx, 11);
{
setState(1336);
match(CALENDAR_QUARTER);
setState(1337);
match(LPAREN);
setState(1338);
dateFieldName();
setState(1339);
match(RPAREN);
}
break;
case 12:
enterOuterAlt(_localctx, 12);
{
setState(1341);
match(CALENDAR_YEAR);
setState(1342);
match(LPAREN);
setState(1343);
dateFieldName();
setState(1344);
match(RPAREN);
}
break;
case 13:
enterOuterAlt(_localctx, 13);
{
setState(1346);
match(DAY_IN_MONTH);
setState(1347);
match(LPAREN);
setState(1348);
dateFieldName();
setState(1349);
match(RPAREN);
}
break;
case 14:
enterOuterAlt(_localctx, 14);
{
setState(1351);
match(DAY_IN_WEEK);
setState(1352);
match(LPAREN);
setState(1353);
dateFieldName();
setState(1354);
match(RPAREN);
}
break;
case 15:
enterOuterAlt(_localctx, 15);
{
setState(1356);
match(DAY_IN_YEAR);
setState(1357);
match(LPAREN);
setState(1358);
dateFieldName();
setState(1359);
match(RPAREN);
}
break;
case 16:
enterOuterAlt(_localctx, 16);
{
setState(1361);
match(DAY_ONLY);
setState(1362);
match(LPAREN);
setState(1363);
dateFieldName();
setState(1364);
match(RPAREN);
}
break;
case 17:
enterOuterAlt(_localctx, 17);
{
setState(1366);
match(FISCAL_MONTH);
setState(1367);
match(LPAREN);
setState(1368);
dateFieldName();
setState(1369);
match(RPAREN);
}
break;
case 18:
enterOuterAlt(_localctx, 18);
{
setState(1371);
match(FISCAL_QUARTER);
setState(1372);
match(LPAREN);
setState(1373);
dateFieldName();
setState(1374);
match(RPAREN);
}
break;
case 19:
enterOuterAlt(_localctx, 19);
{
setState(1376);
match(FISCAL_YEAR);
setState(1377);
match(LPAREN);
setState(1378);
dateFieldName();
setState(1379);
match(RPAREN);
}
break;
case 20:
enterOuterAlt(_localctx, 20);
{
setState(1381);
match(HOUR_IN_DAY);
setState(1382);
match(LPAREN);
setState(1383);
dateFieldName();
setState(1384);
match(RPAREN);
}
break;
case 21:
enterOuterAlt(_localctx, 21);
{
setState(1386);
match(WEEK_IN_MONTH);
setState(1387);
match(LPAREN);
setState(1388);
dateFieldName();
setState(1389);
match(RPAREN);
}
break;
case 22:
enterOuterAlt(_localctx, 22);
{
setState(1391);
match(WEEK_IN_YEAR);
setState(1392);
match(LPAREN);
setState(1393);
dateFieldName();
setState(1394);
match(RPAREN);
}
break;
case 23:
enterOuterAlt(_localctx, 23);
{
setState(1396);
match(FIELDS);
setState(1397);
match(LPAREN);
setState(1398);
soqlFieldsParameter();
setState(1399);
match(RPAREN);
}
break;
case 24:
enterOuterAlt(_localctx, 24);
{
setState(1401);
match(DISTANCE);
setState(1402);
match(LPAREN);
setState(1403);
locationValue();
setState(1404);
match(COMMA);
setState(1405);
locationValue();
setState(1406);
match(COMMA);
setState(1407);
match(StringLiteral);
setState(1408);
match(RPAREN);
}
break;
case 25:
enterOuterAlt(_localctx, 25);
{
setState(1410);
match(GROUPING);
setState(1411);
match(LPAREN);
setState(1412);
fieldName();
setState(1413);
match(RPAREN);
}
break;
case 26:
enterOuterAlt(_localctx, 26);
{
setState(1415);
match(CONVERT_CURRENCY);
setState(1416);
match(LPAREN);
setState(1417);
fieldName();
setState(1418);
match(RPAREN);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DateFieldNameContext extends ParserRuleContext {
public TerminalNode CONVERT_TIMEZONE() { return getToken(ApexParser.CONVERT_TIMEZONE, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public DateFieldNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dateFieldName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDateFieldName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDateFieldName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDateFieldName(this);
else return visitor.visitChildren(this);
}
}
public final DateFieldNameContext dateFieldName() throws RecognitionException {
DateFieldNameContext _localctx = new DateFieldNameContext(_ctx, getState());
enterRule(_localctx, 202, RULE_dateFieldName);
try {
setState(1428);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,135,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1422);
match(CONVERT_TIMEZONE);
setState(1423);
match(LPAREN);
setState(1424);
fieldName();
setState(1425);
match(RPAREN);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1427);
fieldName();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LocationValueContext extends ParserRuleContext {
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public BoundExpressionContext boundExpression() {
return getRuleContext(BoundExpressionContext.class,0);
}
public TerminalNode GEOLOCATION() { return getToken(ApexParser.GEOLOCATION, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public List coordinateValue() {
return getRuleContexts(CoordinateValueContext.class);
}
public CoordinateValueContext coordinateValue(int i) {
return getRuleContext(CoordinateValueContext.class,i);
}
public TerminalNode COMMA() { return getToken(ApexParser.COMMA, 0); }
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public LocationValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_locationValue; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLocationValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLocationValue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLocationValue(this);
else return visitor.visitChildren(this);
}
}
public final LocationValueContext locationValue() throws RecognitionException {
LocationValueContext _localctx = new LocationValueContext(_ctx, getState());
enterRule(_localctx, 204, RULE_locationValue);
try {
setState(1439);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,136,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1430);
fieldName();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1431);
boundExpression();
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1432);
match(GEOLOCATION);
setState(1433);
match(LPAREN);
setState(1434);
coordinateValue();
setState(1435);
match(COMMA);
setState(1436);
coordinateValue();
setState(1437);
match(RPAREN);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class CoordinateValueContext extends ParserRuleContext {
public SignedNumberContext signedNumber() {
return getRuleContext(SignedNumberContext.class,0);
}
public BoundExpressionContext boundExpression() {
return getRuleContext(BoundExpressionContext.class,0);
}
public CoordinateValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_coordinateValue; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterCoordinateValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitCoordinateValue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitCoordinateValue(this);
else return visitor.visitChildren(this);
}
}
public final CoordinateValueContext coordinateValue() throws RecognitionException {
CoordinateValueContext _localctx = new CoordinateValueContext(_ctx, getState());
enterRule(_localctx, 206, RULE_coordinateValue);
try {
setState(1443);
_errHandler.sync(this);
switch (_input.LA(1)) {
case IntegerLiteral:
case NumberLiteral:
case ADD:
case SUB:
enterOuterAlt(_localctx, 1);
{
setState(1441);
signedNumber();
}
break;
case COLON:
enterOuterAlt(_localctx, 2);
{
setState(1442);
boundExpression();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class TypeOfContext extends ParserRuleContext {
public TerminalNode TYPEOF() { return getToken(ApexParser.TYPEOF, 0); }
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public TerminalNode END() { return getToken(ApexParser.END, 0); }
public List whenClause() {
return getRuleContexts(WhenClauseContext.class);
}
public WhenClauseContext whenClause(int i) {
return getRuleContext(WhenClauseContext.class,i);
}
public ElseClauseContext elseClause() {
return getRuleContext(ElseClauseContext.class,0);
}
public TypeOfContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_typeOf; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterTypeOf(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitTypeOf(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitTypeOf(this);
else return visitor.visitChildren(this);
}
}
public final TypeOfContext typeOf() throws RecognitionException {
TypeOfContext _localctx = new TypeOfContext(_ctx, getState());
enterRule(_localctx, 208, RULE_typeOf);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1445);
match(TYPEOF);
setState(1446);
fieldName();
setState(1448);
_errHandler.sync(this);
_la = _input.LA(1);
do {
{
{
setState(1447);
whenClause();
}
}
setState(1450);
_errHandler.sync(this);
_la = _input.LA(1);
} while ( _la==WHEN );
setState(1453);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ELSE) {
{
setState(1452);
elseClause();
}
}
setState(1455);
match(END);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhenClauseContext extends ParserRuleContext {
public TerminalNode WHEN() { return getToken(ApexParser.WHEN, 0); }
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public TerminalNode THEN() { return getToken(ApexParser.THEN, 0); }
public FieldNameListContext fieldNameList() {
return getRuleContext(FieldNameListContext.class,0);
}
public WhenClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whenClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhenClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhenClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhenClause(this);
else return visitor.visitChildren(this);
}
}
public final WhenClauseContext whenClause() throws RecognitionException {
WhenClauseContext _localctx = new WhenClauseContext(_ctx, getState());
enterRule(_localctx, 210, RULE_whenClause);
try {
enterOuterAlt(_localctx, 1);
{
setState(1457);
match(WHEN);
setState(1458);
fieldName();
setState(1459);
match(THEN);
setState(1460);
fieldNameList();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ElseClauseContext extends ParserRuleContext {
public TerminalNode ELSE() { return getToken(ApexParser.ELSE, 0); }
public FieldNameListContext fieldNameList() {
return getRuleContext(FieldNameListContext.class,0);
}
public ElseClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_elseClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterElseClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitElseClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitElseClause(this);
else return visitor.visitChildren(this);
}
}
public final ElseClauseContext elseClause() throws RecognitionException {
ElseClauseContext _localctx = new ElseClauseContext(_ctx, getState());
enterRule(_localctx, 212, RULE_elseClause);
try {
enterOuterAlt(_localctx, 1);
{
setState(1462);
match(ELSE);
setState(1463);
fieldNameList();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FieldNameListContext extends ParserRuleContext {
public List fieldName() {
return getRuleContexts(FieldNameContext.class);
}
public FieldNameContext fieldName(int i) {
return getRuleContext(FieldNameContext.class,i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public FieldNameListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fieldNameList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFieldNameList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFieldNameList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFieldNameList(this);
else return visitor.visitChildren(this);
}
}
public final FieldNameListContext fieldNameList() throws RecognitionException {
FieldNameListContext _localctx = new FieldNameListContext(_ctx, getState());
enterRule(_localctx, 214, RULE_fieldNameList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1465);
fieldName();
setState(1470);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1466);
match(COMMA);
setState(1467);
fieldName();
}
}
setState(1472);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class UsingScopeContext extends ParserRuleContext {
public TerminalNode USING() { return getToken(ApexParser.USING, 0); }
public TerminalNode SCOPE() { return getToken(ApexParser.SCOPE, 0); }
public SoqlIdContext soqlId() {
return getRuleContext(SoqlIdContext.class,0);
}
public UsingScopeContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_usingScope; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterUsingScope(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitUsingScope(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitUsingScope(this);
else return visitor.visitChildren(this);
}
}
public final UsingScopeContext usingScope() throws RecognitionException {
UsingScopeContext _localctx = new UsingScopeContext(_ctx, getState());
enterRule(_localctx, 216, RULE_usingScope);
try {
enterOuterAlt(_localctx, 1);
{
setState(1473);
match(USING);
setState(1474);
match(SCOPE);
setState(1475);
soqlId();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WhereClauseContext extends ParserRuleContext {
public TerminalNode WHERE() { return getToken(ApexParser.WHERE, 0); }
public LogicalExpressionContext logicalExpression() {
return getRuleContext(LogicalExpressionContext.class,0);
}
public WhereClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_whereClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWhereClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWhereClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWhereClause(this);
else return visitor.visitChildren(this);
}
}
public final WhereClauseContext whereClause() throws RecognitionException {
WhereClauseContext _localctx = new WhereClauseContext(_ctx, getState());
enterRule(_localctx, 218, RULE_whereClause);
try {
enterOuterAlt(_localctx, 1);
{
setState(1477);
match(WHERE);
setState(1478);
logicalExpression();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class LogicalExpressionContext extends ParserRuleContext {
public List conditionalExpression() {
return getRuleContexts(ConditionalExpressionContext.class);
}
public ConditionalExpressionContext conditionalExpression(int i) {
return getRuleContext(ConditionalExpressionContext.class,i);
}
public List SOQLAND() { return getTokens(ApexParser.SOQLAND); }
public TerminalNode SOQLAND(int i) {
return getToken(ApexParser.SOQLAND, i);
}
public List SOQLOR() { return getTokens(ApexParser.SOQLOR); }
public TerminalNode SOQLOR(int i) {
return getToken(ApexParser.SOQLOR, i);
}
public TerminalNode NOT() { return getToken(ApexParser.NOT, 0); }
public LogicalExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_logicalExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterLogicalExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitLogicalExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitLogicalExpression(this);
else return visitor.visitChildren(this);
}
}
public final LogicalExpressionContext logicalExpression() throws RecognitionException {
LogicalExpressionContext _localctx = new LogicalExpressionContext(_ctx, getState());
enterRule(_localctx, 220, RULE_logicalExpression);
int _la;
try {
setState(1498);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,143,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1480);
conditionalExpression();
setState(1485);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==SOQLAND) {
{
{
setState(1481);
match(SOQLAND);
setState(1482);
conditionalExpression();
}
}
setState(1487);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1488);
conditionalExpression();
setState(1493);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==SOQLOR) {
{
{
setState(1489);
match(SOQLOR);
setState(1490);
conditionalExpression();
}
}
setState(1495);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1496);
match(NOT);
setState(1497);
conditionalExpression();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ConditionalExpressionContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public LogicalExpressionContext logicalExpression() {
return getRuleContext(LogicalExpressionContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public FieldExpressionContext fieldExpression() {
return getRuleContext(FieldExpressionContext.class,0);
}
public ConditionalExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_conditionalExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterConditionalExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitConditionalExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitConditionalExpression(this);
else return visitor.visitChildren(this);
}
}
public final ConditionalExpressionContext conditionalExpression() throws RecognitionException {
ConditionalExpressionContext _localctx = new ConditionalExpressionContext(_ctx, getState());
enterRule(_localctx, 222, RULE_conditionalExpression);
try {
setState(1505);
_errHandler.sync(this);
switch (_input.LA(1)) {
case LPAREN:
enterOuterAlt(_localctx, 1);
{
setState(1500);
match(LPAREN);
setState(1501);
logicalExpression();
setState(1502);
match(RPAREN);
}
break;
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case SET:
case SHARING:
case SWITCH:
case TRANSIENT:
case TRIGGER:
case WHEN:
case WITH:
case WITHOUT:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case Identifier:
enterOuterAlt(_localctx, 2);
{
setState(1504);
fieldExpression();
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FieldExpressionContext extends ParserRuleContext {
public FieldNameContext fieldName() {
return getRuleContext(FieldNameContext.class,0);
}
public ComparisonOperatorContext comparisonOperator() {
return getRuleContext(ComparisonOperatorContext.class,0);
}
public ValueContext value() {
return getRuleContext(ValueContext.class,0);
}
public SoqlFunctionContext soqlFunction() {
return getRuleContext(SoqlFunctionContext.class,0);
}
public FieldExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_fieldExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFieldExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFieldExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFieldExpression(this);
else return visitor.visitChildren(this);
}
}
public final FieldExpressionContext fieldExpression() throws RecognitionException {
FieldExpressionContext _localctx = new FieldExpressionContext(_ctx, getState());
enterRule(_localctx, 224, RULE_fieldExpression);
try {
setState(1515);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,145,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1507);
fieldName();
setState(1508);
comparisonOperator();
setState(1509);
value();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1511);
soqlFunction();
setState(1512);
comparisonOperator();
setState(1513);
value();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ComparisonOperatorContext extends ParserRuleContext {
public TerminalNode ASSIGN() { return getToken(ApexParser.ASSIGN, 0); }
public TerminalNode NOTEQUAL() { return getToken(ApexParser.NOTEQUAL, 0); }
public TerminalNode LT() { return getToken(ApexParser.LT, 0); }
public TerminalNode GT() { return getToken(ApexParser.GT, 0); }
public TerminalNode LESSANDGREATER() { return getToken(ApexParser.LESSANDGREATER, 0); }
public TerminalNode LIKE() { return getToken(ApexParser.LIKE, 0); }
public TerminalNode IN() { return getToken(ApexParser.IN, 0); }
public TerminalNode NOT() { return getToken(ApexParser.NOT, 0); }
public TerminalNode INCLUDES() { return getToken(ApexParser.INCLUDES, 0); }
public TerminalNode EXCLUDES() { return getToken(ApexParser.EXCLUDES, 0); }
public ComparisonOperatorContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_comparisonOperator; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterComparisonOperator(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitComparisonOperator(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitComparisonOperator(this);
else return visitor.visitChildren(this);
}
}
public final ComparisonOperatorContext comparisonOperator() throws RecognitionException {
ComparisonOperatorContext _localctx = new ComparisonOperatorContext(_ctx, getState());
enterRule(_localctx, 226, RULE_comparisonOperator);
try {
setState(1532);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,146,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1517);
match(ASSIGN);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1518);
match(NOTEQUAL);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1519);
match(LT);
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1520);
match(GT);
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(1521);
match(LT);
setState(1522);
match(ASSIGN);
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(1523);
match(GT);
setState(1524);
match(ASSIGN);
}
break;
case 7:
enterOuterAlt(_localctx, 7);
{
setState(1525);
match(LESSANDGREATER);
}
break;
case 8:
enterOuterAlt(_localctx, 8);
{
setState(1526);
match(LIKE);
}
break;
case 9:
enterOuterAlt(_localctx, 9);
{
setState(1527);
match(IN);
}
break;
case 10:
enterOuterAlt(_localctx, 10);
{
setState(1528);
match(NOT);
setState(1529);
match(IN);
}
break;
case 11:
enterOuterAlt(_localctx, 11);
{
setState(1530);
match(INCLUDES);
}
break;
case 12:
enterOuterAlt(_localctx, 12);
{
setState(1531);
match(EXCLUDES);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ValueContext extends ParserRuleContext {
public TerminalNode NULL() { return getToken(ApexParser.NULL, 0); }
public TerminalNode BooleanLiteral() { return getToken(ApexParser.BooleanLiteral, 0); }
public SignedNumberContext signedNumber() {
return getRuleContext(SignedNumberContext.class,0);
}
public TerminalNode StringLiteral() { return getToken(ApexParser.StringLiteral, 0); }
public TerminalNode DateLiteral() { return getToken(ApexParser.DateLiteral, 0); }
public TerminalNode DateTimeLiteral() { return getToken(ApexParser.DateTimeLiteral, 0); }
public DateFormulaContext dateFormula() {
return getRuleContext(DateFormulaContext.class,0);
}
public TerminalNode IntegralCurrencyLiteral() { return getToken(ApexParser.IntegralCurrencyLiteral, 0); }
public TerminalNode DOT() { return getToken(ApexParser.DOT, 0); }
public TerminalNode IntegerLiteral() { return getToken(ApexParser.IntegerLiteral, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public SubQueryContext subQuery() {
return getRuleContext(SubQueryContext.class,0);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public ValueListContext valueList() {
return getRuleContext(ValueListContext.class,0);
}
public BoundExpressionContext boundExpression() {
return getRuleContext(BoundExpressionContext.class,0);
}
public ValueContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_value; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterValue(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitValue(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitValue(this);
else return visitor.visitChildren(this);
}
}
public final ValueContext value() throws RecognitionException {
ValueContext _localctx = new ValueContext(_ctx, getState());
enterRule(_localctx, 228, RULE_value);
int _la;
try {
setState(1554);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,149,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1534);
match(NULL);
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1535);
match(BooleanLiteral);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1536);
signedNumber();
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1537);
match(StringLiteral);
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(1538);
match(DateLiteral);
}
break;
case 6:
enterOuterAlt(_localctx, 6);
{
setState(1539);
match(DateTimeLiteral);
}
break;
case 7:
enterOuterAlt(_localctx, 7);
{
setState(1540);
dateFormula();
}
break;
case 8:
enterOuterAlt(_localctx, 8);
{
setState(1541);
match(IntegralCurrencyLiteral);
setState(1546);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==DOT) {
{
setState(1542);
match(DOT);
setState(1544);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==IntegerLiteral) {
{
setState(1543);
match(IntegerLiteral);
}
}
}
}
}
break;
case 9:
enterOuterAlt(_localctx, 9);
{
setState(1548);
match(LPAREN);
setState(1549);
subQuery();
setState(1550);
match(RPAREN);
}
break;
case 10:
enterOuterAlt(_localctx, 10);
{
setState(1552);
valueList();
}
break;
case 11:
enterOuterAlt(_localctx, 11);
{
setState(1553);
boundExpression();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class ValueListContext extends ParserRuleContext {
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public List value() {
return getRuleContexts(ValueContext.class);
}
public ValueContext value(int i) {
return getRuleContext(ValueContext.class,i);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public ValueListContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_valueList; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterValueList(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitValueList(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitValueList(this);
else return visitor.visitChildren(this);
}
}
public final ValueListContext valueList() throws RecognitionException {
ValueListContext _localctx = new ValueListContext(_ctx, getState());
enterRule(_localctx, 230, RULE_valueList);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1556);
match(LPAREN);
setState(1557);
value();
setState(1562);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1558);
match(COMMA);
setState(1559);
value();
}
}
setState(1564);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1565);
match(RPAREN);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class SignedNumberContext extends ParserRuleContext {
public TerminalNode IntegerLiteral() { return getToken(ApexParser.IntegerLiteral, 0); }
public TerminalNode NumberLiteral() { return getToken(ApexParser.NumberLiteral, 0); }
public TerminalNode ADD() { return getToken(ApexParser.ADD, 0); }
public TerminalNode SUB() { return getToken(ApexParser.SUB, 0); }
public SignedNumberContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_signedNumber; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterSignedNumber(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitSignedNumber(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitSignedNumber(this);
else return visitor.visitChildren(this);
}
}
public final SignedNumberContext signedNumber() throws RecognitionException {
SignedNumberContext _localctx = new SignedNumberContext(_ctx, getState());
enterRule(_localctx, 232, RULE_signedNumber);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1568);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==ADD || _la==SUB) {
{
setState(1567);
_la = _input.LA(1);
if ( !(_la==ADD || _la==SUB) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
setState(1570);
_la = _input.LA(1);
if ( !(_la==IntegerLiteral || _la==NumberLiteral) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class WithClauseContext extends ParserRuleContext {
public TerminalNode WITH() { return getToken(ApexParser.WITH, 0); }
public TerminalNode DATA() { return getToken(ApexParser.DATA, 0); }
public TerminalNode CATEGORY() { return getToken(ApexParser.CATEGORY, 0); }
public FilteringExpressionContext filteringExpression() {
return getRuleContext(FilteringExpressionContext.class,0);
}
public TerminalNode SECURITY_ENFORCED() { return getToken(ApexParser.SECURITY_ENFORCED, 0); }
public TerminalNode SYSTEM_MODE() { return getToken(ApexParser.SYSTEM_MODE, 0); }
public TerminalNode USER_MODE() { return getToken(ApexParser.USER_MODE, 0); }
public LogicalExpressionContext logicalExpression() {
return getRuleContext(LogicalExpressionContext.class,0);
}
public WithClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_withClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterWithClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitWithClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitWithClause(this);
else return visitor.visitChildren(this);
}
}
public final WithClauseContext withClause() throws RecognitionException {
WithClauseContext _localctx = new WithClauseContext(_ctx, getState());
enterRule(_localctx, 234, RULE_withClause);
try {
setState(1584);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,152,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1572);
match(WITH);
setState(1573);
match(DATA);
setState(1574);
match(CATEGORY);
setState(1575);
filteringExpression();
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1576);
match(WITH);
setState(1577);
match(SECURITY_ENFORCED);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1578);
match(WITH);
setState(1579);
match(SYSTEM_MODE);
}
break;
case 4:
enterOuterAlt(_localctx, 4);
{
setState(1580);
match(WITH);
setState(1581);
match(USER_MODE);
}
break;
case 5:
enterOuterAlt(_localctx, 5);
{
setState(1582);
match(WITH);
setState(1583);
logicalExpression();
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FilteringExpressionContext extends ParserRuleContext {
public List dataCategorySelection() {
return getRuleContexts(DataCategorySelectionContext.class);
}
public DataCategorySelectionContext dataCategorySelection(int i) {
return getRuleContext(DataCategorySelectionContext.class,i);
}
public List AND() { return getTokens(ApexParser.AND); }
public TerminalNode AND(int i) {
return getToken(ApexParser.AND, i);
}
public FilteringExpressionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_filteringExpression; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFilteringExpression(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFilteringExpression(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFilteringExpression(this);
else return visitor.visitChildren(this);
}
}
public final FilteringExpressionContext filteringExpression() throws RecognitionException {
FilteringExpressionContext _localctx = new FilteringExpressionContext(_ctx, getState());
enterRule(_localctx, 236, RULE_filteringExpression);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1586);
dataCategorySelection();
setState(1591);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==AND) {
{
{
setState(1587);
match(AND);
setState(1588);
dataCategorySelection();
}
}
setState(1593);
_errHandler.sync(this);
_la = _input.LA(1);
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DataCategorySelectionContext extends ParserRuleContext {
public SoqlIdContext soqlId() {
return getRuleContext(SoqlIdContext.class,0);
}
public FilteringSelectorContext filteringSelector() {
return getRuleContext(FilteringSelectorContext.class,0);
}
public DataCategoryNameContext dataCategoryName() {
return getRuleContext(DataCategoryNameContext.class,0);
}
public DataCategorySelectionContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dataCategorySelection; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDataCategorySelection(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDataCategorySelection(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDataCategorySelection(this);
else return visitor.visitChildren(this);
}
}
public final DataCategorySelectionContext dataCategorySelection() throws RecognitionException {
DataCategorySelectionContext _localctx = new DataCategorySelectionContext(_ctx, getState());
enterRule(_localctx, 238, RULE_dataCategorySelection);
try {
enterOuterAlt(_localctx, 1);
{
setState(1594);
soqlId();
setState(1595);
filteringSelector();
setState(1596);
dataCategoryName();
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class DataCategoryNameContext extends ParserRuleContext {
public List soqlId() {
return getRuleContexts(SoqlIdContext.class);
}
public SoqlIdContext soqlId(int i) {
return getRuleContext(SoqlIdContext.class,i);
}
public List LPAREN() { return getTokens(ApexParser.LPAREN); }
public TerminalNode LPAREN(int i) {
return getToken(ApexParser.LPAREN, i);
}
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public DataCategoryNameContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_dataCategoryName; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterDataCategoryName(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitDataCategoryName(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitDataCategoryName(this);
else return visitor.visitChildren(this);
}
}
public final DataCategoryNameContext dataCategoryName() throws RecognitionException {
DataCategoryNameContext _localctx = new DataCategoryNameContext(_ctx, getState());
enterRule(_localctx, 240, RULE_dataCategoryName);
int _la;
try {
setState(1610);
_errHandler.sync(this);
switch (_input.LA(1)) {
case AFTER:
case BEFORE:
case GET:
case INHERITED:
case INSTANCEOF:
case SET:
case SHARING:
case SWITCH:
case TRANSIENT:
case TRIGGER:
case WHEN:
case WITH:
case WITHOUT:
case SYSTEM:
case USER:
case SELECT:
case COUNT:
case FROM:
case AS:
case USING:
case SCOPE:
case WHERE:
case ORDER:
case BY:
case LIMIT:
case SOQLAND:
case SOQLOR:
case NOT:
case AVG:
case COUNT_DISTINCT:
case MIN:
case MAX:
case SUM:
case TYPEOF:
case END:
case THEN:
case LIKE:
case IN:
case INCLUDES:
case EXCLUDES:
case ASC:
case DESC:
case NULLS:
case FIRST:
case LAST:
case GROUP:
case ALL:
case ROWS:
case VIEW:
case HAVING:
case ROLLUP:
case TOLABEL:
case OFFSET:
case DATA:
case CATEGORY:
case AT:
case ABOVE:
case BELOW:
case ABOVE_OR_BELOW:
case SECURITY_ENFORCED:
case SYSTEM_MODE:
case USER_MODE:
case REFERENCE:
case CUBE:
case FORMAT:
case TRACKING:
case VIEWSTAT:
case CUSTOM:
case STANDARD:
case DISTANCE:
case GEOLOCATION:
case GROUPING:
case CONVERT_CURRENCY:
case CALENDAR_MONTH:
case CALENDAR_QUARTER:
case CALENDAR_YEAR:
case DAY_IN_MONTH:
case DAY_IN_WEEK:
case DAY_IN_YEAR:
case DAY_ONLY:
case FISCAL_MONTH:
case FISCAL_QUARTER:
case FISCAL_YEAR:
case HOUR_IN_DAY:
case WEEK_IN_MONTH:
case WEEK_IN_YEAR:
case CONVERT_TIMEZONE:
case YESTERDAY:
case TODAY:
case TOMORROW:
case LAST_WEEK:
case THIS_WEEK:
case NEXT_WEEK:
case LAST_MONTH:
case THIS_MONTH:
case NEXT_MONTH:
case LAST_90_DAYS:
case NEXT_90_DAYS:
case LAST_N_DAYS_N:
case NEXT_N_DAYS_N:
case N_DAYS_AGO_N:
case NEXT_N_WEEKS_N:
case LAST_N_WEEKS_N:
case N_WEEKS_AGO_N:
case NEXT_N_MONTHS_N:
case LAST_N_MONTHS_N:
case N_MONTHS_AGO_N:
case THIS_QUARTER:
case LAST_QUARTER:
case NEXT_QUARTER:
case NEXT_N_QUARTERS_N:
case LAST_N_QUARTERS_N:
case N_QUARTERS_AGO_N:
case THIS_YEAR:
case LAST_YEAR:
case NEXT_YEAR:
case NEXT_N_YEARS_N:
case LAST_N_YEARS_N:
case N_YEARS_AGO_N:
case THIS_FISCAL_QUARTER:
case LAST_FISCAL_QUARTER:
case NEXT_FISCAL_QUARTER:
case NEXT_N_FISCAL_QUARTERS_N:
case LAST_N_FISCAL_QUARTERS_N:
case N_FISCAL_QUARTERS_AGO_N:
case THIS_FISCAL_YEAR:
case LAST_FISCAL_YEAR:
case NEXT_FISCAL_YEAR:
case NEXT_N_FISCAL_YEARS_N:
case LAST_N_FISCAL_YEARS_N:
case N_FISCAL_YEARS_AGO_N:
case IntegralCurrencyLiteral:
case FIND:
case EMAIL:
case NAME:
case PHONE:
case SIDEBAR:
case FIELDS:
case METADATA:
case PRICEBOOKID:
case NETWORK:
case SNIPPET:
case TARGET_LENGTH:
case DIVISION:
case RETURNING:
case LISTVIEW:
case Identifier:
enterOuterAlt(_localctx, 1);
{
setState(1598);
soqlId();
}
break;
case LPAREN:
enterOuterAlt(_localctx, 2);
{
setState(1599);
match(LPAREN);
setState(1600);
soqlId();
setState(1605);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1601);
match(COMMA);
setState(1602);
soqlId();
}
}
setState(1607);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1608);
match(LPAREN);
}
break;
default:
throw new NoViableAltException(this);
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class FilteringSelectorContext extends ParserRuleContext {
public TerminalNode AT() { return getToken(ApexParser.AT, 0); }
public TerminalNode ABOVE() { return getToken(ApexParser.ABOVE, 0); }
public TerminalNode BELOW() { return getToken(ApexParser.BELOW, 0); }
public TerminalNode ABOVE_OR_BELOW() { return getToken(ApexParser.ABOVE_OR_BELOW, 0); }
public FilteringSelectorContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_filteringSelector; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterFilteringSelector(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitFilteringSelector(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitFilteringSelector(this);
else return visitor.visitChildren(this);
}
}
public final FilteringSelectorContext filteringSelector() throws RecognitionException {
FilteringSelectorContext _localctx = new FilteringSelectorContext(_ctx, getState());
enterRule(_localctx, 242, RULE_filteringSelector);
int _la;
try {
enterOuterAlt(_localctx, 1);
{
setState(1612);
_la = _input.LA(1);
if ( !(((((_la - 99)) & ~0x3f) == 0 && ((1L << (_la - 99)) & ((1L << (AT - 99)) | (1L << (ABOVE - 99)) | (1L << (BELOW - 99)) | (1L << (ABOVE_OR_BELOW - 99)))) != 0)) ) {
_errHandler.recoverInline(this);
}
else {
if ( _input.LA(1)==Token.EOF ) matchedEOF = true;
_errHandler.reportMatch(this);
consume();
}
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class GroupByClauseContext extends ParserRuleContext {
public TerminalNode GROUP() { return getToken(ApexParser.GROUP, 0); }
public TerminalNode BY() { return getToken(ApexParser.BY, 0); }
public SelectListContext selectList() {
return getRuleContext(SelectListContext.class,0);
}
public TerminalNode HAVING() { return getToken(ApexParser.HAVING, 0); }
public LogicalExpressionContext logicalExpression() {
return getRuleContext(LogicalExpressionContext.class,0);
}
public TerminalNode ROLLUP() { return getToken(ApexParser.ROLLUP, 0); }
public TerminalNode LPAREN() { return getToken(ApexParser.LPAREN, 0); }
public List fieldName() {
return getRuleContexts(FieldNameContext.class);
}
public FieldNameContext fieldName(int i) {
return getRuleContext(FieldNameContext.class,i);
}
public TerminalNode RPAREN() { return getToken(ApexParser.RPAREN, 0); }
public List COMMA() { return getTokens(ApexParser.COMMA); }
public TerminalNode COMMA(int i) {
return getToken(ApexParser.COMMA, i);
}
public TerminalNode CUBE() { return getToken(ApexParser.CUBE, 0); }
public GroupByClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_groupByClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterGroupByClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitGroupByClause(this);
}
@Override
public T accept(ParseTreeVisitor extends T> visitor) {
if ( visitor instanceof ApexParserVisitor ) return ((ApexParserVisitor extends T>)visitor).visitGroupByClause(this);
else return visitor.visitChildren(this);
}
}
public final GroupByClauseContext groupByClause() throws RecognitionException {
GroupByClauseContext _localctx = new GroupByClauseContext(_ctx, getState());
enterRule(_localctx, 244, RULE_groupByClause);
int _la;
try {
setState(1649);
_errHandler.sync(this);
switch ( getInterpreter().adaptivePredict(_input,159,_ctx) ) {
case 1:
enterOuterAlt(_localctx, 1);
{
setState(1614);
match(GROUP);
setState(1615);
match(BY);
setState(1616);
selectList();
setState(1619);
_errHandler.sync(this);
_la = _input.LA(1);
if (_la==HAVING) {
{
setState(1617);
match(HAVING);
setState(1618);
logicalExpression();
}
}
}
break;
case 2:
enterOuterAlt(_localctx, 2);
{
setState(1621);
match(GROUP);
setState(1622);
match(BY);
setState(1623);
match(ROLLUP);
setState(1624);
match(LPAREN);
setState(1625);
fieldName();
setState(1630);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1626);
match(COMMA);
setState(1627);
fieldName();
}
}
setState(1632);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1633);
match(RPAREN);
}
break;
case 3:
enterOuterAlt(_localctx, 3);
{
setState(1635);
match(GROUP);
setState(1636);
match(BY);
setState(1637);
match(CUBE);
setState(1638);
match(LPAREN);
setState(1639);
fieldName();
setState(1644);
_errHandler.sync(this);
_la = _input.LA(1);
while (_la==COMMA) {
{
{
setState(1640);
match(COMMA);
setState(1641);
fieldName();
}
}
setState(1646);
_errHandler.sync(this);
_la = _input.LA(1);
}
setState(1647);
match(RPAREN);
}
break;
}
}
catch (RecognitionException re) {
_localctx.exception = re;
_errHandler.reportError(this, re);
_errHandler.recover(this, re);
}
finally {
exitRule();
}
return _localctx;
}
public static class OrderByClauseContext extends ParserRuleContext {
public TerminalNode ORDER() { return getToken(ApexParser.ORDER, 0); }
public TerminalNode BY() { return getToken(ApexParser.BY, 0); }
public FieldOrderListContext fieldOrderList() {
return getRuleContext(FieldOrderListContext.class,0);
}
public OrderByClauseContext(ParserRuleContext parent, int invokingState) {
super(parent, invokingState);
}
@Override public int getRuleIndex() { return RULE_orderByClause; }
@Override
public void enterRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).enterOrderByClause(this);
}
@Override
public void exitRule(ParseTreeListener listener) {
if ( listener instanceof ApexParserListener ) ((ApexParserListener)listener).exitOrderByClause(this);
}
@Override
public