1 /* 2 * Copyright (C) 2011 Google Inc. 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package com.google.doclava.parser; 18 19 import org.antlr.runtime.BaseRecognizer; 20 import org.antlr.runtime.BitSet; 21 import org.antlr.runtime.DFA; 22 import org.antlr.runtime.EarlyExitException; 23 import org.antlr.runtime.IntStream; 24 import org.antlr.runtime.MismatchedSetException; 25 import org.antlr.runtime.NoViableAltException; 26 import org.antlr.runtime.RecognitionException; 27 import org.antlr.runtime.RecognizerSharedState; 28 import org.antlr.runtime.TokenStream; 29 import org.antlr.runtime.debug.DebugEventListener; 30 import org.antlr.runtime.debug.DebugEventSocketProxy; 31 import org.antlr.runtime.debug.DebugParser; 32 33 import java.io.IOException; 34 import java.util.HashMap; 35 /** A Java 1.5 grammar for ANTLR v3 derived from the spec 36 * 37 * This is a very close representation of the spec; the changes 38 * are comestic (remove left recursion) and also fixes (the spec 39 * isn't exactly perfect). I have run this on the 1.4.2 source 40 * and some nasty looking enums from 1.5, but have not really 41 * tested for 1.5 compatibility. 42 * 43 * I built this with: java -Xmx100M org.antlr.Tool java.g 44 * and got two errors that are ok (for now): 45 * java.g:691:9: Decision can match input such as 46 * "'0'..'9'{'E', 'e'}{'+', '-'}'0'..'9'{'D', 'F', 'd', 'f'}" 47 * using multiple alternatives: 3, 4 48 * As a result, alternative(s) 4 were disabled for that input 49 * java.g:734:35: Decision can match input such as "{'$', 'A'..'Z', 50 * '_', 'a'..'z', '\u00C0'..'\u00D6', '\u00D8'..'\u00F6', 51 * '\u00F8'..'\u1FFF', '\u3040'..'\u318F', '\u3300'..'\u337F', 52 * '\u3400'..'\u3D2D', '\u4E00'..'\u9FFF', '\uF900'..'\uFAFF'}" 53 * using multiple alternatives: 1, 2 54 * As a result, alternative(s) 2 were disabled for that input 55 * 56 * You can turn enum on/off as a keyword :) 57 * 58 * Version 1.0 -- initial release July 5, 2006 (requires 3.0b2 or higher) 59 * 60 * Primary author: Terence Parr, July 2006 61 * 62 * Version 1.0.1 -- corrections by Koen Vanderkimpen & Marko van Dooren, 63 * October 25, 2006; 64 * fixed normalInterfaceDeclaration: now uses typeParameters instead 65 * of typeParameter (according to JLS, 3rd edition) 66 * fixed castExpression: no longer allows expression next to type 67 * (according to semantics in JLS, in contrast with syntax in JLS) 68 * 69 * Version 1.0.2 -- Terence Parr, Nov 27, 2006 70 * java spec I built this from had some bizarre for-loop control. 71 * Looked weird and so I looked elsewhere...Yep, it's messed up. 72 * simplified. 73 * 74 * Version 1.0.3 -- Chris Hogue, Feb 26, 2007 75 * Factored out an annotationName rule and used it in the annotation rule. 76 * Not sure why, but typeName wasn't recognizing references to inner 77 * annotations (e.g. @InterfaceName.InnerAnnotation()) 78 * Factored out the elementValue section of an annotation reference. Created 79 * elementValuePair and elementValuePairs rules, then used them in the 80 * annotation rule. Allows it to recognize annotation references with 81 * multiple, comma separated attributes. 82 * Updated elementValueArrayInitializer so that it allows multiple elements. 83 * (It was only allowing 0 or 1 element). 84 * Updated localVariableDeclaration to allow annotations. Interestingly the JLS 85 * doesn't appear to indicate this is legal, but it does work as of at least 86 * JDK 1.5.0_06. 87 * Moved the Identifier portion of annotationTypeElementRest to annotationMethodRest. 88 * Because annotationConstantRest already references variableDeclarator which 89 * has the Identifier portion in it, the parser would fail on constants in 90 * annotation definitions because it expected two identifiers. 91 * Added optional trailing ';' to the alternatives in annotationTypeElementRest. 92 * Wouldn't handle an inner interface that has a trailing ';'. 93 * Swapped the expression and type rule reference order in castExpression to 94 * make it check for genericized casts first. It was failing to recognize a 95 * statement like "Class<Byte> TYPE = (Class<Byte>)...;" because it was seeing 96 * 'Class<Byte' in the cast expression as a less than expression, then failing 97 * on the '>'. 98 * Changed createdName to use typeArguments instead of nonWildcardTypeArguments. 99 * 100 * Changed the 'this' alternative in primary to allow 'identifierSuffix' rather than 101 * just 'arguments'. The case it couldn't handle was a call to an explicit 102 * generic method invocation (e.g. this.<E>doSomething()). Using identifierSuffix 103 * may be overly aggressive--perhaps should create a more constrained thisSuffix rule? 104 * 105 * Version 1.0.4 -- Hiroaki Nakamura, May 3, 2007 106 * 107 * Fixed formalParameterDecls, localVariableDeclaration, forInit, 108 * and forVarControl to use variableModifier* not 'final'? (annotation)? 109 * 110 * Version 1.0.5 -- Terence, June 21, 2007 111 * --a[i].foo didn't work. Fixed unaryExpression 112 * 113 * Version 1.0.6 -- John Ridgway, March 17, 2008 114 * Made "assert" a switchable keyword like "enum". 115 * Fixed compilationUnit to disallow "annotation importDeclaration ...". 116 * Changed "Identifier ('.' Identifier)*" to "qualifiedName" in more 117 * places. 118 * Changed modifier* and/or variableModifier* to classOrInterfaceModifiers, 119 * modifiers or variableModifiers, as appropriate. 120 * Renamed "bound" to "typeBound" to better match language in the JLS. 121 * Added "memberDeclaration" which rewrites to methodDeclaration or 122 * fieldDeclaration and pulled type into memberDeclaration. So we parse 123 * type and then move on to decide whether we're dealing with a field 124 * or a method. 125 * Modified "constructorDeclaration" to use "constructorBody" instead of 126 * "methodBody". constructorBody starts with explicitConstructorInvocation, 127 * then goes on to blockStatement*. Pulling explicitConstructorInvocation 128 * out of expressions allowed me to simplify "primary". 129 * Changed variableDeclarator to simplify it. 130 * Changed type to use classOrInterfaceType, thus simplifying it; of course 131 * I then had to add classOrInterfaceType, but it is used in several 132 * places. 133 * Fixed annotations, old version allowed "@X(y,z)", which is illegal. 134 * Added optional comma to end of "elementValueArrayInitializer"; as per JLS. 135 * Changed annotationTypeElementRest to use normalClassDeclaration and 136 * normalInterfaceDeclaration rather than classDeclaration and 137 * interfaceDeclaration, thus getting rid of a couple of grammar ambiguities. 138 * Split localVariableDeclaration into localVariableDeclarationStatement 139 * (includes the terminating semi-colon) and localVariableDeclaration. 140 * This allowed me to use localVariableDeclaration in "forInit" clauses, 141 * simplifying them. 142 * Changed switchBlockStatementGroup to use multiple labels. This adds an 143 * ambiguity, but if one uses appropriately greedy parsing it yields the 144 * parse that is closest to the meaning of the switch statement. 145 * Renamed "forVarControl" to "enhancedForControl" -- JLS language. 146 * Added semantic predicates to test for shift operations rather than other 147 * things. Thus, for instance, the string "< <" will never be treated 148 * as a left-shift operator. 149 * In "creator" we rule out "nonWildcardTypeArguments" on arrayCreation, 150 * which are illegal. 151 * Moved "nonWildcardTypeArguments into innerCreator. 152 * Removed 'super' superSuffix from explicitGenericInvocation, since that 153 * is only used in explicitConstructorInvocation at the beginning of a 154 * constructorBody. (This is part of the simplification of expressions 155 * mentioned earlier.) 156 * Simplified primary (got rid of those things that are only used in 157 * explicitConstructorInvocation). 158 * Lexer -- removed "Exponent?" from FloatingPointLiteral choice 4, since it 159 * led to an ambiguity. 160 * 161 * This grammar successfully parses every .java file in the JDK 1.5 source 162 * tree (excluding those whose file names include '-', which are not 163 * valid Java compilation units). 164 * 165 * Known remaining problems: 166 * "Letter" and "JavaIDDigit" are wrong. The actual specification of 167 * "Letter" should be "a character for which the method 168 * Character.isJavaIdentifierStart(int) returns true." A "Java 169 * letter-or-digit is a character for which the method 170 * Character.isJavaIdentifierPart(int) returns true." 171 */ 172 public class JavaParser extends DebugParser { 173 public static final String[] tokenNames = new String[] { 174 "<invalid>", "<EOR>", "<DOWN>", "<UP>", "IDENTIFIER", "INTLITERAL", "LONGLITERAL", "FLOATLITERAL", "DOUBLELITERAL", "CHARLITERAL", "STRINGLITERAL", "TRUE", "FALSE", "NULL", "IntegerNumber", "LongSuffix", "HexPrefix", "HexDigit", "Exponent", "NonIntegerNumber", "FloatSuffix", "DoubleSuffix", "EscapeSequence", "UNICODECHAR", "UNICODEPART", "WS", "COMMENT", "LINE_COMMENT", "ABSTRACT", "ASSERT", "BOOLEAN", "BREAK", "BYTE", "CASE", "CATCH", "CHAR", "CLASS", "CONST", "CONTINUE", "DEFAULT", "DO", "DOUBLE", "ELSE", "ENUM", "EXTENDS", "FINAL", "FINALLY", "FLOAT", "FOR", "GOTO", "IF", "IMPLEMENTS", "IMPORT", "INSTANCEOF", "INT", "INTERFACE", "LONG", "NATIVE", "NEW", "PACKAGE", "PRIVATE", "PROTECTED", "PUBLIC", "RETURN", "SHORT", "STATIC", "STRICTFP", "SUPER", "SWITCH", "SYNCHRONIZED", "THIS", "THROW", "THROWS", "TRANSIENT", "TRY", "VOID", "VOLATILE", "WHILE", "LPAREN", "RPAREN", "LBRACE", "RBRACE", "LBRACKET", "RBRACKET", "SEMI", "COMMA", "DOT", "ELLIPSIS", "EQ", "BANG", "TILDE", "QUES", "COLON", "EQEQ", "AMPAMP", "BARBAR", "PLUSPLUS", "SUBSUB", "PLUS", "SUB", "STAR", "SLASH", "AMP", "BAR", "CARET", "PERCENT", "PLUSEQ", "SUBEQ", "STAREQ", "SLASHEQ", "AMPEQ", "BAREQ", "CARETEQ", "PERCENTEQ", "MONKEYS_AT", "BANGEQ", "GT", "LT", "IdentifierStart", "IdentifierPart", "SurrogateIdentifer" 175 }; 176 public static final int EOF=-1; 177 public static final int IDENTIFIER=4; 178 public static final int INTLITERAL=5; 179 public static final int LONGLITERAL=6; 180 public static final int FLOATLITERAL=7; 181 public static final int DOUBLELITERAL=8; 182 public static final int CHARLITERAL=9; 183 public static final int STRINGLITERAL=10; 184 public static final int TRUE=11; 185 public static final int FALSE=12; 186 public static final int NULL=13; 187 public static final int IntegerNumber=14; 188 public static final int LongSuffix=15; 189 public static final int HexPrefix=16; 190 public static final int HexDigit=17; 191 public static final int Exponent=18; 192 public static final int NonIntegerNumber=19; 193 public static final int FloatSuffix=20; 194 public static final int DoubleSuffix=21; 195 public static final int EscapeSequence=22; 196 public static final int UNICODECHAR=23; 197 public static final int UNICODEPART=24; 198 public static final int WS=25; 199 public static final int COMMENT=26; 200 public static final int LINE_COMMENT=27; 201 public static final int ABSTRACT=28; 202 public static final int ASSERT=29; 203 public static final int BOOLEAN=30; 204 public static final int BREAK=31; 205 public static final int BYTE=32; 206 public static final int CASE=33; 207 public static final int CATCH=34; 208 public static final int CHAR=35; 209 public static final int CLASS=36; 210 public static final int CONST=37; 211 public static final int CONTINUE=38; 212 public static final int DEFAULT=39; 213 public static final int DO=40; 214 public static final int DOUBLE=41; 215 public static final int ELSE=42; 216 public static final int ENUM=43; 217 public static final int EXTENDS=44; 218 public static final int FINAL=45; 219 public static final int FINALLY=46; 220 public static final int FLOAT=47; 221 public static final int FOR=48; 222 public static final int GOTO=49; 223 public static final int IF=50; 224 public static final int IMPLEMENTS=51; 225 public static final int IMPORT=52; 226 public static final int INSTANCEOF=53; 227 public static final int INT=54; 228 public static final int INTERFACE=55; 229 public static final int LONG=56; 230 public static final int NATIVE=57; 231 public static final int NEW=58; 232 public static final int PACKAGE=59; 233 public static final int PRIVATE=60; 234 public static final int PROTECTED=61; 235 public static final int PUBLIC=62; 236 public static final int RETURN=63; 237 public static final int SHORT=64; 238 public static final int STATIC=65; 239 public static final int STRICTFP=66; 240 public static final int SUPER=67; 241 public static final int SWITCH=68; 242 public static final int SYNCHRONIZED=69; 243 public static final int THIS=70; 244 public static final int THROW=71; 245 public static final int THROWS=72; 246 public static final int TRANSIENT=73; 247 public static final int TRY=74; 248 public static final int VOID=75; 249 public static final int VOLATILE=76; 250 public static final int WHILE=77; 251 public static final int LPAREN=78; 252 public static final int RPAREN=79; 253 public static final int LBRACE=80; 254 public static final int RBRACE=81; 255 public static final int LBRACKET=82; 256 public static final int RBRACKET=83; 257 public static final int SEMI=84; 258 public static final int COMMA=85; 259 public static final int DOT=86; 260 public static final int ELLIPSIS=87; 261 public static final int EQ=88; 262 public static final int BANG=89; 263 public static final int TILDE=90; 264 public static final int QUES=91; 265 public static final int COLON=92; 266 public static final int EQEQ=93; 267 public static final int AMPAMP=94; 268 public static final int BARBAR=95; 269 public static final int PLUSPLUS=96; 270 public static final int SUBSUB=97; 271 public static final int PLUS=98; 272 public static final int SUB=99; 273 public static final int STAR=100; 274 public static final int SLASH=101; 275 public static final int AMP=102; 276 public static final int BAR=103; 277 public static final int CARET=104; 278 public static final int PERCENT=105; 279 public static final int PLUSEQ=106; 280 public static final int SUBEQ=107; 281 public static final int STAREQ=108; 282 public static final int SLASHEQ=109; 283 public static final int AMPEQ=110; 284 public static final int BAREQ=111; 285 public static final int CARETEQ=112; 286 public static final int PERCENTEQ=113; 287 public static final int MONKEYS_AT=114; 288 public static final int BANGEQ=115; 289 public static final int GT=116; 290 public static final int LT=117; 291 public static final int IdentifierStart=118; 292 public static final int IdentifierPart=119; 293 public static final int SurrogateIdentifer=120; 294 295 // delegates 296 // delegators 297 298 public static final String[] ruleNames = new String[] { 299 "invalidRule", "typeList", "synpred114_Java", "synpred175_Java", 300 "synpred19_Java", "elementValuePairs", "identifierSuffix", "interfaceFieldDeclaration", 301 "synpred69_Java", "synpred263_Java", "synpred231_Java", "synpred267_Java", 302 "synpred111_Java", "block", "synpred261_Java", "elementValuePair", 303 "typeArgument", "synpred264_Java", "synpred95_Java", "synpred93_Java", 304 "synpred215_Java", "normalInterfaceDeclaration", "enumHeader", "synpred236_Java", 305 "createdName", "synpred271_Java", "synpred230_Java", "synpred30_Java", 306 "synpred212_Java", "synpred82_Java", "synpred128_Java", "synpred83_Java", 307 "synpred255_Java", "synpred190_Java", "arrayInitializer", "interfaceDeclaration", 308 "synpred92_Java", "localVariableHeader", "packageDeclaration", "formalParameter", 309 "catchClause", "synpred27_Java", "synpred270_Java", "synpred46_Java", 310 "synpred1_Java", "synpred4_Java", "synpred233_Java", "synpred120_Java", 311 "superSuffix", "literal", "classDeclaration", "synpred72_Java", 312 "synpred160_Java", "arguments", "synpred80_Java", "formalParameterDecls", 313 "synpred113_Java", "inclusiveOrExpression", "synpred71_Java", "selector", 314 "synpred194_Java", "synpred265_Java", "synpred173_Java", "synpred141_Java", 315 "synpred187_Java", "trystatement", "synpred133_Java", "interfaceHeader", 316 "synpred73_Java", "localVariableDeclarationStatement", "synpred102_Java", 317 "synpred90_Java", "equalityExpression", "synpred177_Java", "synpred149_Java", 318 "interfaceBodyDeclaration", "classCreatorRest", "synpred121_Java", 319 "synpred105_Java", "typeArguments", "synpred60_Java", "synpred195_Java", 320 "fieldDeclaration", "synpred269_Java", "synpred250_Java", "multiplicativeExpression", 321 "qualifiedNameList", "synpred86_Java", "synpred148_Java", "synpred142_Java", 322 "synpred65_Java", "synpred75_Java", "synpred235_Java", "synpred192_Java", 323 "synpred144_Java", "castExpression", "enumBody", "synpred70_Java", 324 "synpred33_Java", "synpred54_Java", "annotationTypeDeclaration", 325 "annotationHeader", "synpred107_Java", "synpred35_Java", "creator", 326 "nonWildcardTypeArguments", "variableInitializer", "enumConstants", 327 "synpred34_Java", "interfaceMethodDeclaration", "type", "synpred135_Java", 328 "synpred119_Java", "conditionalAndExpression", "synpred9_Java", 329 "synpred125_Java", "synpred40_Java", "synpred257_Java", "enumConstant", 330 "synpred143_Java", "synpred132_Java", "synpred146_Java", "synpred188_Java", 331 "ellipsisParameterDecl", "synpred245_Java", "synpred167_Java", "compilationUnit", 332 "synpred259_Java", "synpred64_Java", "synpred181_Java", "synpred23_Java", 333 "synpred12_Java", "synpred74_Java", "explicitConstructorInvocation", 334 "synpred266_Java", "synpred197_Java", "synpred147_Java", "synpred15_Java", 335 "synpred178_Java", "synpred174_Java", "exclusiveOrExpression", "forstatement", 336 "synpred7_Java", "synpred76_Java", "synpred224_Java", "parExpression", 337 "synpred241_Java", "synpred159_Java", "synpred260_Java", "synpred50_Java", 338 "synpred166_Java", "annotationMethodDeclaration", "synpred208_Java", 339 "synpred106_Java", "classOrInterfaceType", "qualifiedImportName", 340 "statement", "typeBound", "methodHeader", "synpred249_Java", "synpred55_Java", 341 "synpred131_Java", "classBodyDeclaration", "synpred189_Java", "synpred51_Java", 342 "synpred227_Java", "synpred220_Java", "synpred123_Java", "andExpression", 343 "synpred200_Java", "synpred165_Java", "relationalExpression", "annotationTypeBody", 344 "synpred210_Java", "synpred109_Java", "conditionalOrExpression", 345 "synpred161_Java", "classOrInterfaceDeclaration", "synpred180_Java", 346 "synpred154_Java", "elementValueArrayInitializer", "synpred14_Java", 347 "innerCreator", "synpred26_Java", "synpred52_Java", "synpred198_Java", 348 "synpred219_Java", "synpred126_Java", "synpred85_Java", "synpred88_Java", 349 "synpred68_Java", "synpred3_Java", "synpred203_Java", "annotations", 350 "elementValue", "synpred205_Java", "synpred6_Java", "synpred32_Java", 351 "synpred209_Java", "assignmentOperator", "synpred262_Java", "synpred139_Java", 352 "synpred29_Java", "synpred204_Java", "synpred118_Java", "synpred94_Java", 353 "synpred84_Java", "synpred63_Java", "conditionalExpression", "synpred56_Java", 354 "synpred162_Java", "primitiveType", "synpred240_Java", "synpred216_Java", 355 "synpred79_Java", "synpred99_Java", "additiveExpression", "synpred78_Java", 356 "modifiers", "synpred184_Java", "synpred168_Java", "synpred48_Java", 357 "switchBlockStatementGroups", "blockStatement", "synpred193_Java", 358 "classBody", "interfaceBody", "synpred67_Java", "synpred5_Java", 359 "synpred58_Java", "synpred254_Java", "localVariableDeclaration", 360 "annotationTypeElementDeclaration", "synpred251_Java", "arrayCreator", 361 "synpred226_Java", "synpred239_Java", "synpred191_Java", "synpred24_Java", 362 "normalClassDeclaration", "synpred98_Java", "synpred53_Java", "synpred145_Java", 363 "synpred22_Java", "synpred150_Java", "synpred238_Java", "synpred207_Java", 364 "variableModifiers", "typeParameters", "synpred38_Java", "synpred129_Java", 365 "enumBodyDeclarations", "synpred172_Java", "synpred16_Java", "synpred100_Java", 366 "fieldHeader", "synpred41_Java", "synpred248_Java", "synpred152_Java", 367 "synpred214_Java", "switchBlockStatementGroup", "synpred199_Java", 368 "switchLabel", "qualifiedName", "synpred137_Java", "synpred237_Java", 369 "synpred223_Java", "synpred156_Java", "synpred243_Java", "synpred182_Java", 370 "synpred138_Java", "synpred77_Java", "synpred127_Java", "synpred112_Java", 371 "unaryExpressionNotPlusMinus", "synpred42_Java", "synpred89_Java", 372 "formalParameters", "synpred225_Java", "synpred136_Java", "synpred186_Java", 373 "synpred122_Java", "synpred87_Java", "synpred244_Java", "synpred97_Java", 374 "synpred229_Java", "synpred170_Java", "shiftOp", "synpred134_Java", 375 "synpred253_Java", "synpred44_Java", "memberDecl", "synpred157_Java", 376 "synpred246_Java", "synpred49_Java", "synpred31_Java", "synpred256_Java", 377 "unaryExpression", "synpred13_Java", "synpred213_Java", "synpred155_Java", 378 "typeHeader", "synpred91_Java", "instanceOfExpression", "variableDeclarator", 379 "synpred140_Java", "synpred25_Java", "synpred117_Java", "synpred2_Java", 380 "synpred222_Java", "synpred10_Java", "synpred104_Java", "synpred115_Java", 381 "synpred221_Java", "synpred45_Java", "synpred211_Java", "typeParameter", 382 "synpred36_Java", "synpred103_Java", "synpred39_Java", "synpred201_Java", 383 "methodDeclaration", "synpred62_Java", "synpred110_Java", "classHeader", 384 "synpred101_Java", "synpred21_Java", "synpred196_Java", "synpred96_Java", 385 "synpred61_Java", "synpred228_Java", "synpred28_Java", "synpred218_Java", 386 "synpred179_Java", "normalParameterDecl", "enumDeclaration", "synpred17_Java", 387 "synpred18_Java", "synpred108_Java", "synpred43_Java", "synpred206_Java", 388 "synpred169_Java", "synpred130_Java", "synpred242_Java", "synpred252_Java", 389 "synpred151_Java", "forInit", "shiftExpression", "synpred81_Java", 390 "synpred247_Java", "synpred20_Java", "catches", "synpred202_Java", 391 "synpred47_Java", "synpred185_Java", "synpred158_Java", "synpred66_Java", 392 "synpred11_Java", "synpred8_Java", "synpred163_Java", "synpred217_Java", 393 "primary", "synpred153_Java", "synpred57_Java", "synpred258_Java", 394 "expressionList", "annotation", "expression", "synpred176_Java", 395 "synpred171_Java", "synpred164_Java", "importDeclaration", "synpred124_Java", 396 "synpred268_Java", "synpred234_Java", "relationalOp", "synpred59_Java", 397 "synpred37_Java", "synpred183_Java", "synpred232_Java", "synpred116_Java", 398 "typeDeclaration" 399 }; 400 public static final boolean[] decisionCanBacktrack = new boolean[] { 401 false, // invalid decision 402 false, true, false, false, false, false, false, false, false, false, 403 false, true, false, false, true, false, false, false, false, 404 false, false, false, false, false, false, false, false, false, 405 false, false, true, false, false, false, false, false, false, 406 false, true, false, false, true, false, false, false, false, 407 false, false, true, false, false, false, true, false, false, 408 false, false, false, false, false, false, false, false, false, 409 false, false, false, false, false, false, true, true, false, 410 false, false, true, false, false, false, false, false, false, 411 false, false, false, false, true, false, false, true, false, 412 false, false, true, false, false, false, true, false, false, 413 false, true, false, false, false, false, false, true, true, 414 false, false, false, false, false, false, false, false, false, 415 false, false, false, false, false, false, false, false, false, 416 false, false, true, true, true, true, true, true, false, false, 417 false, false, false, false, true, false, false, false, true, 418 false, true, false, true, false, false, false, false, false, 419 false, false, false, false, false, false, false, false, false, 420 false, false, false, false, false, false, true, false, false, 421 false, false, false, false, false, false, false, false, false, 422 false, false, false, false, false, false, false, false, false, 423 false, false, false 424 }; 425 426 427 public int ruleLevel = 0; 428 public int getRuleLevel() { return ruleLevel; } 429 public void incRuleLevel() { ruleLevel++; } 430 public void decRuleLevel() { ruleLevel--; } 431 public JavaParser(TokenStream input) { 432 this(input, DebugEventSocketProxy.DEFAULT_DEBUGGER_PORT, new RecognizerSharedState()); 433 } 434 public JavaParser(TokenStream input, int port, RecognizerSharedState state) { 435 super(input, state); 436 this.state.ruleMemo = new HashMap[381+1]; 437 438 DebugEventSocketProxy proxy = 439 new DebugEventSocketProxy(this, port, null); 440 setDebugListener(proxy); 441 try { 442 proxy.handshake(); 443 } 444 catch (IOException ioe) { 445 reportError(ioe); 446 } 447 } 448 public JavaParser(TokenStream input, DebugEventListener dbg) { 449 super(input, dbg, new RecognizerSharedState()); 450 this.state.ruleMemo = new HashMap[381+1]; 451 452 } 453 protected boolean evalPredicate(boolean result, String predicate) { 454 dbg.semanticPredicate(result, predicate); 455 return result; 456 } 457 458 459 public String[] getTokenNames() { return JavaParser.tokenNames; } 460 public String getGrammarFileName() { return "src/com/google/doclava/parser/Java.g"; } 461 462 463 464 // $ANTLR start "compilationUnit" 465 // src/com/google/doclava/parser/Java.g:293:1: compilationUnit : ( ( annotations )? packageDeclaration )? ( importDeclaration )* ( typeDeclaration )* ; 466 public final void compilationUnit() throws RecognitionException { 467 int compilationUnit_StartIndex = input.index(); 468 try { dbg.enterRule(getGrammarFileName(), "compilationUnit"); 469 if ( getRuleLevel()==0 ) {dbg.commence();} 470 incRuleLevel(); 471 dbg.location(293, 1); 472 473 try { 474 if ( state.backtracking>0 && alreadyParsedRule(input, 1) ) { return ; } 475 // src/com/google/doclava/parser/Java.g:298:5: ( ( ( annotations )? packageDeclaration )? ( importDeclaration )* ( typeDeclaration )* ) 476 dbg.enterAlt(1); 477 478 // src/com/google/doclava/parser/Java.g:298:9: ( ( annotations )? packageDeclaration )? ( importDeclaration )* ( typeDeclaration )* 479 { 480 dbg.location(298,9); 481 // src/com/google/doclava/parser/Java.g:298:9: ( ( annotations )? packageDeclaration )? 482 int alt2=2; 483 try { dbg.enterSubRule(2); 484 try { dbg.enterDecision(2, decisionCanBacktrack[2]); 485 486 try { 487 isCyclicDecision = true; 488 alt2 = dfa2.predict(input); 489 } 490 catch (NoViableAltException nvae) { 491 dbg.recognitionException(nvae); 492 throw nvae; 493 } 494 } finally {dbg.exitDecision(2);} 495 496 switch (alt2) { 497 case 1 : 498 dbg.enterAlt(1); 499 500 // src/com/google/doclava/parser/Java.g:298:13: ( annotations )? packageDeclaration 501 { 502 dbg.location(298,13); 503 // src/com/google/doclava/parser/Java.g:298:13: ( annotations )? 504 int alt1=2; 505 try { dbg.enterSubRule(1); 506 try { dbg.enterDecision(1, decisionCanBacktrack[1]); 507 508 int LA1_0 = input.LA(1); 509 510 if ( (LA1_0==MONKEYS_AT) ) { 511 alt1=1; 512 } 513 } finally {dbg.exitDecision(1);} 514 515 switch (alt1) { 516 case 1 : 517 dbg.enterAlt(1); 518 519 // src/com/google/doclava/parser/Java.g:298:14: annotations 520 { 521 dbg.location(298,14); 522 pushFollow(FOLLOW_annotations_in_compilationUnit64); 523 annotations(); 524 525 state._fsp--; 526 if (state.failed) return ; 527 528 } 529 break; 530 531 } 532 } finally {dbg.exitSubRule(1);} 533 534 dbg.location(300,13); 535 pushFollow(FOLLOW_packageDeclaration_in_compilationUnit93); 536 packageDeclaration(); 537 538 state._fsp--; 539 if (state.failed) return ; 540 541 } 542 break; 543 544 } 545 } finally {dbg.exitSubRule(2);} 546 547 dbg.location(302,9); 548 // src/com/google/doclava/parser/Java.g:302:9: ( importDeclaration )* 549 try { dbg.enterSubRule(3); 550 551 loop3: 552 do { 553 int alt3=2; 554 try { dbg.enterDecision(3, decisionCanBacktrack[3]); 555 556 int LA3_0 = input.LA(1); 557 558 if ( (LA3_0==IMPORT) ) { 559 alt3=1; 560 } 561 562 563 } finally {dbg.exitDecision(3);} 564 565 switch (alt3) { 566 case 1 : 567 dbg.enterAlt(1); 568 569 // src/com/google/doclava/parser/Java.g:302:10: importDeclaration 570 { 571 dbg.location(302,10); 572 pushFollow(FOLLOW_importDeclaration_in_compilationUnit115); 573 importDeclaration(); 574 575 state._fsp--; 576 if (state.failed) return ; 577 578 } 579 break; 580 581 default : 582 break loop3; 583 } 584 } while (true); 585 } finally {dbg.exitSubRule(3);} 586 587 dbg.location(304,9); 588 // src/com/google/doclava/parser/Java.g:304:9: ( typeDeclaration )* 589 try { dbg.enterSubRule(4); 590 591 loop4: 592 do { 593 int alt4=2; 594 try { dbg.enterDecision(4, decisionCanBacktrack[4]); 595 596 int LA4_0 = input.LA(1); 597 598 if ( (LA4_0==IDENTIFIER||LA4_0==ABSTRACT||LA4_0==BOOLEAN||LA4_0==BYTE||(LA4_0>=CHAR && LA4_0<=CLASS)||LA4_0==DOUBLE||LA4_0==ENUM||LA4_0==FINAL||LA4_0==FLOAT||(LA4_0>=INT && LA4_0<=NATIVE)||(LA4_0>=PRIVATE && LA4_0<=PUBLIC)||(LA4_0>=SHORT && LA4_0<=STRICTFP)||LA4_0==SYNCHRONIZED||LA4_0==TRANSIENT||(LA4_0>=VOID && LA4_0<=VOLATILE)||LA4_0==SEMI||LA4_0==MONKEYS_AT||LA4_0==LT) ) { 599 alt4=1; 600 } 601 602 603 } finally {dbg.exitDecision(4);} 604 605 switch (alt4) { 606 case 1 : 607 dbg.enterAlt(1); 608 609 // src/com/google/doclava/parser/Java.g:304:10: typeDeclaration 610 { 611 dbg.location(304,10); 612 pushFollow(FOLLOW_typeDeclaration_in_compilationUnit137); 613 typeDeclaration(); 614 615 state._fsp--; 616 if (state.failed) return ; 617 618 } 619 break; 620 621 default : 622 break loop4; 623 } 624 } while (true); 625 } finally {dbg.exitSubRule(4);} 626 627 628 } 629 630 } 631 catch (RecognitionException re) { 632 reportError(re); 633 recover(input,re); 634 } 635 finally { 636 if ( state.backtracking>0 ) { memoize(input, 1, compilationUnit_StartIndex); } 637 } 638 dbg.location(306, 5); 639 640 } 641 finally { 642 dbg.exitRule(getGrammarFileName(), "compilationUnit"); 643 decRuleLevel(); 644 if ( getRuleLevel()==0 ) {dbg.terminate();} 645 } 646 647 return ; 648 } 649 // $ANTLR end "compilationUnit" 650 651 652 // $ANTLR start "packageDeclaration" 653 // src/com/google/doclava/parser/Java.g:308:1: packageDeclaration : 'package' qualifiedName ';' ; 654 public final void packageDeclaration() throws RecognitionException { 655 int packageDeclaration_StartIndex = input.index(); 656 try { dbg.enterRule(getGrammarFileName(), "packageDeclaration"); 657 if ( getRuleLevel()==0 ) {dbg.commence();} 658 incRuleLevel(); 659 dbg.location(308, 1); 660 661 try { 662 if ( state.backtracking>0 && alreadyParsedRule(input, 2) ) { return ; } 663 // src/com/google/doclava/parser/Java.g:309:5: ( 'package' qualifiedName ';' ) 664 dbg.enterAlt(1); 665 666 // src/com/google/doclava/parser/Java.g:309:9: 'package' qualifiedName ';' 667 { 668 dbg.location(309,9); 669 match(input,PACKAGE,FOLLOW_PACKAGE_in_packageDeclaration167); if (state.failed) return ; 670 dbg.location(309,19); 671 pushFollow(FOLLOW_qualifiedName_in_packageDeclaration169); 672 qualifiedName(); 673 674 state._fsp--; 675 if (state.failed) return ; 676 dbg.location(310,9); 677 match(input,SEMI,FOLLOW_SEMI_in_packageDeclaration179); if (state.failed) return ; 678 679 } 680 681 } 682 catch (RecognitionException re) { 683 reportError(re); 684 recover(input,re); 685 } 686 finally { 687 if ( state.backtracking>0 ) { memoize(input, 2, packageDeclaration_StartIndex); } 688 } 689 dbg.location(311, 5); 690 691 } 692 finally { 693 dbg.exitRule(getGrammarFileName(), "packageDeclaration"); 694 decRuleLevel(); 695 if ( getRuleLevel()==0 ) {dbg.terminate();} 696 } 697 698 return ; 699 } 700 // $ANTLR end "packageDeclaration" 701 702 703 // $ANTLR start "importDeclaration" 704 // src/com/google/doclava/parser/Java.g:313:1: importDeclaration : ( 'import' ( 'static' )? IDENTIFIER '.' '*' ';' | 'import' ( 'static' )? IDENTIFIER ( '.' IDENTIFIER )+ ( '.' '*' )? ';' ); 705 public final void importDeclaration() throws RecognitionException { 706 int importDeclaration_StartIndex = input.index(); 707 try { dbg.enterRule(getGrammarFileName(), "importDeclaration"); 708 if ( getRuleLevel()==0 ) {dbg.commence();} 709 incRuleLevel(); 710 dbg.location(313, 1); 711 712 try { 713 if ( state.backtracking>0 && alreadyParsedRule(input, 3) ) { return ; } 714 // src/com/google/doclava/parser/Java.g:314:5: ( 'import' ( 'static' )? IDENTIFIER '.' '*' ';' | 'import' ( 'static' )? IDENTIFIER ( '.' IDENTIFIER )+ ( '.' '*' )? ';' ) 715 int alt9=2; 716 try { dbg.enterDecision(9, decisionCanBacktrack[9]); 717 718 int LA9_0 = input.LA(1); 719 720 if ( (LA9_0==IMPORT) ) { 721 int LA9_1 = input.LA(2); 722 723 if ( (LA9_1==STATIC) ) { 724 int LA9_2 = input.LA(3); 725 726 if ( (LA9_2==IDENTIFIER) ) { 727 int LA9_3 = input.LA(4); 728 729 if ( (LA9_3==DOT) ) { 730 int LA9_4 = input.LA(5); 731 732 if ( (LA9_4==STAR) ) { 733 alt9=1; 734 } 735 else if ( (LA9_4==IDENTIFIER) ) { 736 alt9=2; 737 } 738 else { 739 if (state.backtracking>0) {state.failed=true; return ;} 740 NoViableAltException nvae = 741 new NoViableAltException("", 9, 4, input); 742 743 dbg.recognitionException(nvae); 744 throw nvae; 745 } 746 } 747 else { 748 if (state.backtracking>0) {state.failed=true; return ;} 749 NoViableAltException nvae = 750 new NoViableAltException("", 9, 3, input); 751 752 dbg.recognitionException(nvae); 753 throw nvae; 754 } 755 } 756 else { 757 if (state.backtracking>0) {state.failed=true; return ;} 758 NoViableAltException nvae = 759 new NoViableAltException("", 9, 2, input); 760 761 dbg.recognitionException(nvae); 762 throw nvae; 763 } 764 } 765 else if ( (LA9_1==IDENTIFIER) ) { 766 int LA9_3 = input.LA(3); 767 768 if ( (LA9_3==DOT) ) { 769 int LA9_4 = input.LA(4); 770 771 if ( (LA9_4==STAR) ) { 772 alt9=1; 773 } 774 else if ( (LA9_4==IDENTIFIER) ) { 775 alt9=2; 776 } 777 else { 778 if (state.backtracking>0) {state.failed=true; return ;} 779 NoViableAltException nvae = 780 new NoViableAltException("", 9, 4, input); 781 782 dbg.recognitionException(nvae); 783 throw nvae; 784 } 785 } 786 else { 787 if (state.backtracking>0) {state.failed=true; return ;} 788 NoViableAltException nvae = 789 new NoViableAltException("", 9, 3, input); 790 791 dbg.recognitionException(nvae); 792 throw nvae; 793 } 794 } 795 else { 796 if (state.backtracking>0) {state.failed=true; return ;} 797 NoViableAltException nvae = 798 new NoViableAltException("", 9, 1, input); 799 800 dbg.recognitionException(nvae); 801 throw nvae; 802 } 803 } 804 else { 805 if (state.backtracking>0) {state.failed=true; return ;} 806 NoViableAltException nvae = 807 new NoViableAltException("", 9, 0, input); 808 809 dbg.recognitionException(nvae); 810 throw nvae; 811 } 812 } finally {dbg.exitDecision(9);} 813 814 switch (alt9) { 815 case 1 : 816 dbg.enterAlt(1); 817 818 // src/com/google/doclava/parser/Java.g:314:9: 'import' ( 'static' )? IDENTIFIER '.' '*' ';' 819 { 820 dbg.location(314,9); 821 match(input,IMPORT,FOLLOW_IMPORT_in_importDeclaration198); if (state.failed) return ; 822 dbg.location(315,9); 823 // src/com/google/doclava/parser/Java.g:315:9: ( 'static' )? 824 int alt5=2; 825 try { dbg.enterSubRule(5); 826 try { dbg.enterDecision(5, decisionCanBacktrack[5]); 827 828 int LA5_0 = input.LA(1); 829 830 if ( (LA5_0==STATIC) ) { 831 alt5=1; 832 } 833 } finally {dbg.exitDecision(5);} 834 835 switch (alt5) { 836 case 1 : 837 dbg.enterAlt(1); 838 839 // src/com/google/doclava/parser/Java.g:315:10: 'static' 840 { 841 dbg.location(315,10); 842 match(input,STATIC,FOLLOW_STATIC_in_importDeclaration209); if (state.failed) return ; 843 844 } 845 break; 846 847 } 848 } finally {dbg.exitSubRule(5);} 849 850 dbg.location(317,9); 851 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_importDeclaration230); if (state.failed) return ; 852 dbg.location(317,20); 853 match(input,DOT,FOLLOW_DOT_in_importDeclaration232); if (state.failed) return ; 854 dbg.location(317,24); 855 match(input,STAR,FOLLOW_STAR_in_importDeclaration234); if (state.failed) return ; 856 dbg.location(318,9); 857 match(input,SEMI,FOLLOW_SEMI_in_importDeclaration244); if (state.failed) return ; 858 859 } 860 break; 861 case 2 : 862 dbg.enterAlt(2); 863 864 // src/com/google/doclava/parser/Java.g:319:9: 'import' ( 'static' )? IDENTIFIER ( '.' IDENTIFIER )+ ( '.' '*' )? ';' 865 { 866 dbg.location(319,9); 867 match(input,IMPORT,FOLLOW_IMPORT_in_importDeclaration254); if (state.failed) return ; 868 dbg.location(320,9); 869 // src/com/google/doclava/parser/Java.g:320:9: ( 'static' )? 870 int alt6=2; 871 try { dbg.enterSubRule(6); 872 try { dbg.enterDecision(6, decisionCanBacktrack[6]); 873 874 int LA6_0 = input.LA(1); 875 876 if ( (LA6_0==STATIC) ) { 877 alt6=1; 878 } 879 } finally {dbg.exitDecision(6);} 880 881 switch (alt6) { 882 case 1 : 883 dbg.enterAlt(1); 884 885 // src/com/google/doclava/parser/Java.g:320:10: 'static' 886 { 887 dbg.location(320,10); 888 match(input,STATIC,FOLLOW_STATIC_in_importDeclaration265); if (state.failed) return ; 889 890 } 891 break; 892 893 } 894 } finally {dbg.exitSubRule(6);} 895 896 dbg.location(322,9); 897 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_importDeclaration286); if (state.failed) return ; 898 dbg.location(323,9); 899 // src/com/google/doclava/parser/Java.g:323:9: ( '.' IDENTIFIER )+ 900 int cnt7=0; 901 try { dbg.enterSubRule(7); 902 903 loop7: 904 do { 905 int alt7=2; 906 try { dbg.enterDecision(7, decisionCanBacktrack[7]); 907 908 int LA7_0 = input.LA(1); 909 910 if ( (LA7_0==DOT) ) { 911 int LA7_1 = input.LA(2); 912 913 if ( (LA7_1==IDENTIFIER) ) { 914 alt7=1; 915 } 916 917 918 } 919 920 921 } finally {dbg.exitDecision(7);} 922 923 switch (alt7) { 924 case 1 : 925 dbg.enterAlt(1); 926 927 // src/com/google/doclava/parser/Java.g:323:10: '.' IDENTIFIER 928 { 929 dbg.location(323,10); 930 match(input,DOT,FOLLOW_DOT_in_importDeclaration297); if (state.failed) return ; 931 dbg.location(323,14); 932 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_importDeclaration299); if (state.failed) return ; 933 934 } 935 break; 936 937 default : 938 if ( cnt7 >= 1 ) break loop7; 939 if (state.backtracking>0) {state.failed=true; return ;} 940 EarlyExitException eee = 941 new EarlyExitException(7, input); 942 dbg.recognitionException(eee); 943 944 throw eee; 945 } 946 cnt7++; 947 } while (true); 948 } finally {dbg.exitSubRule(7);} 949 950 dbg.location(325,9); 951 // src/com/google/doclava/parser/Java.g:325:9: ( '.' '*' )? 952 int alt8=2; 953 try { dbg.enterSubRule(8); 954 try { dbg.enterDecision(8, decisionCanBacktrack[8]); 955 956 int LA8_0 = input.LA(1); 957 958 if ( (LA8_0==DOT) ) { 959 alt8=1; 960 } 961 } finally {dbg.exitDecision(8);} 962 963 switch (alt8) { 964 case 1 : 965 dbg.enterAlt(1); 966 967 // src/com/google/doclava/parser/Java.g:325:10: '.' '*' 968 { 969 dbg.location(325,10); 970 match(input,DOT,FOLLOW_DOT_in_importDeclaration321); if (state.failed) return ; 971 dbg.location(325,14); 972 match(input,STAR,FOLLOW_STAR_in_importDeclaration323); if (state.failed) return ; 973 974 } 975 break; 976 977 } 978 } finally {dbg.exitSubRule(8);} 979 980 dbg.location(327,9); 981 match(input,SEMI,FOLLOW_SEMI_in_importDeclaration344); if (state.failed) return ; 982 983 } 984 break; 985 986 } 987 } 988 catch (RecognitionException re) { 989 reportError(re); 990 recover(input,re); 991 } 992 finally { 993 if ( state.backtracking>0 ) { memoize(input, 3, importDeclaration_StartIndex); } 994 } 995 dbg.location(328, 5); 996 997 } 998 finally { 999 dbg.exitRule(getGrammarFileName(), "importDeclaration"); 1000 decRuleLevel(); 1001 if ( getRuleLevel()==0 ) {dbg.terminate();} 1002 } 1003 1004 return ; 1005 } 1006 // $ANTLR end "importDeclaration" 1007 1008 1009 // $ANTLR start "qualifiedImportName" 1010 // src/com/google/doclava/parser/Java.g:330:1: qualifiedImportName : IDENTIFIER ( '.' IDENTIFIER )* ; 1011 public final void qualifiedImportName() throws RecognitionException { 1012 int qualifiedImportName_StartIndex = input.index(); 1013 try { dbg.enterRule(getGrammarFileName(), "qualifiedImportName"); 1014 if ( getRuleLevel()==0 ) {dbg.commence();} 1015 incRuleLevel(); 1016 dbg.location(330, 1); 1017 1018 try { 1019 if ( state.backtracking>0 && alreadyParsedRule(input, 4) ) { return ; } 1020 // src/com/google/doclava/parser/Java.g:331:5: ( IDENTIFIER ( '.' IDENTIFIER )* ) 1021 dbg.enterAlt(1); 1022 1023 // src/com/google/doclava/parser/Java.g:331:9: IDENTIFIER ( '.' IDENTIFIER )* 1024 { 1025 dbg.location(331,9); 1026 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_qualifiedImportName363); if (state.failed) return ; 1027 dbg.location(332,9); 1028 // src/com/google/doclava/parser/Java.g:332:9: ( '.' IDENTIFIER )* 1029 try { dbg.enterSubRule(10); 1030 1031 loop10: 1032 do { 1033 int alt10=2; 1034 try { dbg.enterDecision(10, decisionCanBacktrack[10]); 1035 1036 int LA10_0 = input.LA(1); 1037 1038 if ( (LA10_0==DOT) ) { 1039 alt10=1; 1040 } 1041 1042 1043 } finally {dbg.exitDecision(10);} 1044 1045 switch (alt10) { 1046 case 1 : 1047 dbg.enterAlt(1); 1048 1049 // src/com/google/doclava/parser/Java.g:332:10: '.' IDENTIFIER 1050 { 1051 dbg.location(332,10); 1052 match(input,DOT,FOLLOW_DOT_in_qualifiedImportName374); if (state.failed) return ; 1053 dbg.location(332,14); 1054 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_qualifiedImportName376); if (state.failed) return ; 1055 1056 } 1057 break; 1058 1059 default : 1060 break loop10; 1061 } 1062 } while (true); 1063 } finally {dbg.exitSubRule(10);} 1064 1065 1066 } 1067 1068 } 1069 catch (RecognitionException re) { 1070 reportError(re); 1071 recover(input,re); 1072 } 1073 finally { 1074 if ( state.backtracking>0 ) { memoize(input, 4, qualifiedImportName_StartIndex); } 1075 } 1076 dbg.location(334, 5); 1077 1078 } 1079 finally { 1080 dbg.exitRule(getGrammarFileName(), "qualifiedImportName"); 1081 decRuleLevel(); 1082 if ( getRuleLevel()==0 ) {dbg.terminate();} 1083 } 1084 1085 return ; 1086 } 1087 // $ANTLR end "qualifiedImportName" 1088 1089 1090 // $ANTLR start "typeDeclaration" 1091 // src/com/google/doclava/parser/Java.g:336:1: typeDeclaration : ( classOrInterfaceDeclaration | ';' ); 1092 public final void typeDeclaration() throws RecognitionException { 1093 int typeDeclaration_StartIndex = input.index(); 1094 try { dbg.enterRule(getGrammarFileName(), "typeDeclaration"); 1095 if ( getRuleLevel()==0 ) {dbg.commence();} 1096 incRuleLevel(); 1097 dbg.location(336, 1); 1098 1099 try { 1100 if ( state.backtracking>0 && alreadyParsedRule(input, 5) ) { return ; } 1101 // src/com/google/doclava/parser/Java.g:337:5: ( classOrInterfaceDeclaration | ';' ) 1102 int alt11=2; 1103 try { dbg.enterDecision(11, decisionCanBacktrack[11]); 1104 1105 int LA11_0 = input.LA(1); 1106 1107 if ( (LA11_0==IDENTIFIER||LA11_0==ABSTRACT||LA11_0==BOOLEAN||LA11_0==BYTE||(LA11_0>=CHAR && LA11_0<=CLASS)||LA11_0==DOUBLE||LA11_0==ENUM||LA11_0==FINAL||LA11_0==FLOAT||(LA11_0>=INT && LA11_0<=NATIVE)||(LA11_0>=PRIVATE && LA11_0<=PUBLIC)||(LA11_0>=SHORT && LA11_0<=STRICTFP)||LA11_0==SYNCHRONIZED||LA11_0==TRANSIENT||(LA11_0>=VOID && LA11_0<=VOLATILE)||LA11_0==MONKEYS_AT||LA11_0==LT) ) { 1108 alt11=1; 1109 } 1110 else if ( (LA11_0==SEMI) ) { 1111 alt11=2; 1112 } 1113 else { 1114 if (state.backtracking>0) {state.failed=true; return ;} 1115 NoViableAltException nvae = 1116 new NoViableAltException("", 11, 0, input); 1117 1118 dbg.recognitionException(nvae); 1119 throw nvae; 1120 } 1121 } finally {dbg.exitDecision(11);} 1122 1123 switch (alt11) { 1124 case 1 : 1125 dbg.enterAlt(1); 1126 1127 // src/com/google/doclava/parser/Java.g:337:9: classOrInterfaceDeclaration 1128 { 1129 dbg.location(337,9); 1130 pushFollow(FOLLOW_classOrInterfaceDeclaration_in_typeDeclaration406); 1131 classOrInterfaceDeclaration(); 1132 1133 state._fsp--; 1134 if (state.failed) return ; 1135 1136 } 1137 break; 1138 case 2 : 1139 dbg.enterAlt(2); 1140 1141 // src/com/google/doclava/parser/Java.g:338:9: ';' 1142 { 1143 dbg.location(338,9); 1144 match(input,SEMI,FOLLOW_SEMI_in_typeDeclaration416); if (state.failed) return ; 1145 1146 } 1147 break; 1148 1149 } 1150 } 1151 catch (RecognitionException re) { 1152 reportError(re); 1153 recover(input,re); 1154 } 1155 finally { 1156 if ( state.backtracking>0 ) { memoize(input, 5, typeDeclaration_StartIndex); } 1157 } 1158 dbg.location(339, 5); 1159 1160 } 1161 finally { 1162 dbg.exitRule(getGrammarFileName(), "typeDeclaration"); 1163 decRuleLevel(); 1164 if ( getRuleLevel()==0 ) {dbg.terminate();} 1165 } 1166 1167 return ; 1168 } 1169 // $ANTLR end "typeDeclaration" 1170 1171 1172 // $ANTLR start "classOrInterfaceDeclaration" 1173 // src/com/google/doclava/parser/Java.g:341:1: classOrInterfaceDeclaration : ( classDeclaration | interfaceDeclaration ); 1174 public final void classOrInterfaceDeclaration() throws RecognitionException { 1175 int classOrInterfaceDeclaration_StartIndex = input.index(); 1176 try { dbg.enterRule(getGrammarFileName(), "classOrInterfaceDeclaration"); 1177 if ( getRuleLevel()==0 ) {dbg.commence();} 1178 incRuleLevel(); 1179 dbg.location(341, 1); 1180 1181 try { 1182 if ( state.backtracking>0 && alreadyParsedRule(input, 6) ) { return ; } 1183 // src/com/google/doclava/parser/Java.g:342:5: ( classDeclaration | interfaceDeclaration ) 1184 int alt12=2; 1185 try { dbg.enterDecision(12, decisionCanBacktrack[12]); 1186 1187 try { 1188 isCyclicDecision = true; 1189 alt12 = dfa12.predict(input); 1190 } 1191 catch (NoViableAltException nvae) { 1192 dbg.recognitionException(nvae); 1193 throw nvae; 1194 } 1195 } finally {dbg.exitDecision(12);} 1196 1197 switch (alt12) { 1198 case 1 : 1199 dbg.enterAlt(1); 1200 1201 // src/com/google/doclava/parser/Java.g:342:10: classDeclaration 1202 { 1203 dbg.location(342,10); 1204 pushFollow(FOLLOW_classDeclaration_in_classOrInterfaceDeclaration436); 1205 classDeclaration(); 1206 1207 state._fsp--; 1208 if (state.failed) return ; 1209 1210 } 1211 break; 1212 case 2 : 1213 dbg.enterAlt(2); 1214 1215 // src/com/google/doclava/parser/Java.g:343:9: interfaceDeclaration 1216 { 1217 dbg.location(343,9); 1218 pushFollow(FOLLOW_interfaceDeclaration_in_classOrInterfaceDeclaration446); 1219 interfaceDeclaration(); 1220 1221 state._fsp--; 1222 if (state.failed) return ; 1223 1224 } 1225 break; 1226 1227 } 1228 } 1229 catch (RecognitionException re) { 1230 reportError(re); 1231 recover(input,re); 1232 } 1233 finally { 1234 if ( state.backtracking>0 ) { memoize(input, 6, classOrInterfaceDeclaration_StartIndex); } 1235 } 1236 dbg.location(344, 5); 1237 1238 } 1239 finally { 1240 dbg.exitRule(getGrammarFileName(), "classOrInterfaceDeclaration"); 1241 decRuleLevel(); 1242 if ( getRuleLevel()==0 ) {dbg.terminate();} 1243 } 1244 1245 return ; 1246 } 1247 // $ANTLR end "classOrInterfaceDeclaration" 1248 1249 1250 // $ANTLR start "modifiers" 1251 // src/com/google/doclava/parser/Java.g:347:1: modifiers : ( annotation | 'public' | 'protected' | 'private' | 'static' | 'abstract' | 'final' | 'native' | 'synchronized' | 'transient' | 'volatile' | 'strictfp' )* ; 1252 public final void modifiers() throws RecognitionException { 1253 int modifiers_StartIndex = input.index(); 1254 try { dbg.enterRule(getGrammarFileName(), "modifiers"); 1255 if ( getRuleLevel()==0 ) {dbg.commence();} 1256 incRuleLevel(); 1257 dbg.location(347, 1); 1258 1259 try { 1260 if ( state.backtracking>0 && alreadyParsedRule(input, 7) ) { return ; } 1261 // src/com/google/doclava/parser/Java.g:348:5: ( ( annotation | 'public' | 'protected' | 'private' | 'static' | 'abstract' | 'final' | 'native' | 'synchronized' | 'transient' | 'volatile' | 'strictfp' )* ) 1262 dbg.enterAlt(1); 1263 1264 // src/com/google/doclava/parser/Java.g:349:5: ( annotation | 'public' | 'protected' | 'private' | 'static' | 'abstract' | 'final' | 'native' | 'synchronized' | 'transient' | 'volatile' | 'strictfp' )* 1265 { 1266 dbg.location(349,5); 1267 // src/com/google/doclava/parser/Java.g:349:5: ( annotation | 'public' | 'protected' | 'private' | 'static' | 'abstract' | 'final' | 'native' | 'synchronized' | 'transient' | 'volatile' | 'strictfp' )* 1268 try { dbg.enterSubRule(13); 1269 1270 loop13: 1271 do { 1272 int alt13=13; 1273 try { dbg.enterDecision(13, decisionCanBacktrack[13]); 1274 1275 try { 1276 isCyclicDecision = true; 1277 alt13 = dfa13.predict(input); 1278 } 1279 catch (NoViableAltException nvae) { 1280 dbg.recognitionException(nvae); 1281 throw nvae; 1282 } 1283 } finally {dbg.exitDecision(13);} 1284 1285 switch (alt13) { 1286 case 1 : 1287 dbg.enterAlt(1); 1288 1289 // src/com/google/doclava/parser/Java.g:349:10: annotation 1290 { 1291 dbg.location(349,10); 1292 pushFollow(FOLLOW_annotation_in_modifiers473); 1293 annotation(); 1294 1295 state._fsp--; 1296 if (state.failed) return ; 1297 1298 } 1299 break; 1300 case 2 : 1301 dbg.enterAlt(2); 1302 1303 // src/com/google/doclava/parser/Java.g:350:9: 'public' 1304 { 1305 dbg.location(350,9); 1306 match(input,PUBLIC,FOLLOW_PUBLIC_in_modifiers483); if (state.failed) return ; 1307 1308 } 1309 break; 1310 case 3 : 1311 dbg.enterAlt(3); 1312 1313 // src/com/google/doclava/parser/Java.g:351:9: 'protected' 1314 { 1315 dbg.location(351,9); 1316 match(input,PROTECTED,FOLLOW_PROTECTED_in_modifiers493); if (state.failed) return ; 1317 1318 } 1319 break; 1320 case 4 : 1321 dbg.enterAlt(4); 1322 1323 // src/com/google/doclava/parser/Java.g:352:9: 'private' 1324 { 1325 dbg.location(352,9); 1326 match(input,PRIVATE,FOLLOW_PRIVATE_in_modifiers503); if (state.failed) return ; 1327 1328 } 1329 break; 1330 case 5 : 1331 dbg.enterAlt(5); 1332 1333 // src/com/google/doclava/parser/Java.g:353:9: 'static' 1334 { 1335 dbg.location(353,9); 1336 match(input,STATIC,FOLLOW_STATIC_in_modifiers513); if (state.failed) return ; 1337 1338 } 1339 break; 1340 case 6 : 1341 dbg.enterAlt(6); 1342 1343 // src/com/google/doclava/parser/Java.g:354:9: 'abstract' 1344 { 1345 dbg.location(354,9); 1346 match(input,ABSTRACT,FOLLOW_ABSTRACT_in_modifiers523); if (state.failed) return ; 1347 1348 } 1349 break; 1350 case 7 : 1351 dbg.enterAlt(7); 1352 1353 // src/com/google/doclava/parser/Java.g:355:9: 'final' 1354 { 1355 dbg.location(355,9); 1356 match(input,FINAL,FOLLOW_FINAL_in_modifiers533); if (state.failed) return ; 1357 1358 } 1359 break; 1360 case 8 : 1361 dbg.enterAlt(8); 1362 1363 // src/com/google/doclava/parser/Java.g:356:9: 'native' 1364 { 1365 dbg.location(356,9); 1366 match(input,NATIVE,FOLLOW_NATIVE_in_modifiers543); if (state.failed) return ; 1367 1368 } 1369 break; 1370 case 9 : 1371 dbg.enterAlt(9); 1372 1373 // src/com/google/doclava/parser/Java.g:357:9: 'synchronized' 1374 { 1375 dbg.location(357,9); 1376 match(input,SYNCHRONIZED,FOLLOW_SYNCHRONIZED_in_modifiers553); if (state.failed) return ; 1377 1378 } 1379 break; 1380 case 10 : 1381 dbg.enterAlt(10); 1382 1383 // src/com/google/doclava/parser/Java.g:358:9: 'transient' 1384 { 1385 dbg.location(358,9); 1386 match(input,TRANSIENT,FOLLOW_TRANSIENT_in_modifiers563); if (state.failed) return ; 1387 1388 } 1389 break; 1390 case 11 : 1391 dbg.enterAlt(11); 1392 1393 // src/com/google/doclava/parser/Java.g:359:9: 'volatile' 1394 { 1395 dbg.location(359,9); 1396 match(input,VOLATILE,FOLLOW_VOLATILE_in_modifiers573); if (state.failed) return ; 1397 1398 } 1399 break; 1400 case 12 : 1401 dbg.enterAlt(12); 1402 1403 // src/com/google/doclava/parser/Java.g:360:9: 'strictfp' 1404 { 1405 dbg.location(360,9); 1406 match(input,STRICTFP,FOLLOW_STRICTFP_in_modifiers583); if (state.failed) return ; 1407 1408 } 1409 break; 1410 1411 default : 1412 break loop13; 1413 } 1414 } while (true); 1415 } finally {dbg.exitSubRule(13);} 1416 1417 1418 } 1419 1420 } 1421 catch (RecognitionException re) { 1422 reportError(re); 1423 recover(input,re); 1424 } 1425 finally { 1426 if ( state.backtracking>0 ) { memoize(input, 7, modifiers_StartIndex); } 1427 } 1428 dbg.location(362, 5); 1429 1430 } 1431 finally { 1432 dbg.exitRule(getGrammarFileName(), "modifiers"); 1433 decRuleLevel(); 1434 if ( getRuleLevel()==0 ) {dbg.terminate();} 1435 } 1436 1437 return ; 1438 } 1439 // $ANTLR end "modifiers" 1440 1441 1442 // $ANTLR start "variableModifiers" 1443 // src/com/google/doclava/parser/Java.g:365:1: variableModifiers : ( 'final' | annotation )* ; 1444 public final void variableModifiers() throws RecognitionException { 1445 int variableModifiers_StartIndex = input.index(); 1446 try { dbg.enterRule(getGrammarFileName(), "variableModifiers"); 1447 if ( getRuleLevel()==0 ) {dbg.commence();} 1448 incRuleLevel(); 1449 dbg.location(365, 1); 1450 1451 try { 1452 if ( state.backtracking>0 && alreadyParsedRule(input, 8) ) { return ; } 1453 // src/com/google/doclava/parser/Java.g:366:5: ( ( 'final' | annotation )* ) 1454 dbg.enterAlt(1); 1455 1456 // src/com/google/doclava/parser/Java.g:366:9: ( 'final' | annotation )* 1457 { 1458 dbg.location(366,9); 1459 // src/com/google/doclava/parser/Java.g:366:9: ( 'final' | annotation )* 1460 try { dbg.enterSubRule(14); 1461 1462 loop14: 1463 do { 1464 int alt14=3; 1465 try { dbg.enterDecision(14, decisionCanBacktrack[14]); 1466 1467 int LA14_0 = input.LA(1); 1468 1469 if ( (LA14_0==FINAL) ) { 1470 alt14=1; 1471 } 1472 else if ( (LA14_0==MONKEYS_AT) ) { 1473 alt14=2; 1474 } 1475 1476 1477 } finally {dbg.exitDecision(14);} 1478 1479 switch (alt14) { 1480 case 1 : 1481 dbg.enterAlt(1); 1482 1483 // src/com/google/doclava/parser/Java.g:366:13: 'final' 1484 { 1485 dbg.location(366,13); 1486 match(input,FINAL,FOLLOW_FINAL_in_variableModifiers614); if (state.failed) return ; 1487 1488 } 1489 break; 1490 case 2 : 1491 dbg.enterAlt(2); 1492 1493 // src/com/google/doclava/parser/Java.g:367:13: annotation 1494 { 1495 dbg.location(367,13); 1496 pushFollow(FOLLOW_annotation_in_variableModifiers628); 1497 annotation(); 1498 1499 state._fsp--; 1500 if (state.failed) return ; 1501 1502 } 1503 break; 1504 1505 default : 1506 break loop14; 1507 } 1508 } while (true); 1509 } finally {dbg.exitSubRule(14);} 1510 1511 1512 } 1513 1514 } 1515 catch (RecognitionException re) { 1516 reportError(re); 1517 recover(input,re); 1518 } 1519 finally { 1520 if ( state.backtracking>0 ) { memoize(input, 8, variableModifiers_StartIndex); } 1521 } 1522 dbg.location(369, 5); 1523 1524 } 1525 finally { 1526 dbg.exitRule(getGrammarFileName(), "variableModifiers"); 1527 decRuleLevel(); 1528 if ( getRuleLevel()==0 ) {dbg.terminate();} 1529 } 1530 1531 return ; 1532 } 1533 // $ANTLR end "variableModifiers" 1534 1535 1536 // $ANTLR start "classDeclaration" 1537 // src/com/google/doclava/parser/Java.g:372:1: classDeclaration : ( normalClassDeclaration | enumDeclaration ); 1538 public final void classDeclaration() throws RecognitionException { 1539 int classDeclaration_StartIndex = input.index(); 1540 try { dbg.enterRule(getGrammarFileName(), "classDeclaration"); 1541 if ( getRuleLevel()==0 ) {dbg.commence();} 1542 incRuleLevel(); 1543 dbg.location(372, 1); 1544 1545 try { 1546 if ( state.backtracking>0 && alreadyParsedRule(input, 9) ) { return ; } 1547 // src/com/google/doclava/parser/Java.g:373:5: ( normalClassDeclaration | enumDeclaration ) 1548 int alt15=2; 1549 try { dbg.enterDecision(15, decisionCanBacktrack[15]); 1550 1551 try { 1552 isCyclicDecision = true; 1553 alt15 = dfa15.predict(input); 1554 } 1555 catch (NoViableAltException nvae) { 1556 dbg.recognitionException(nvae); 1557 throw nvae; 1558 } 1559 } finally {dbg.exitDecision(15);} 1560 1561 switch (alt15) { 1562 case 1 : 1563 dbg.enterAlt(1); 1564 1565 // src/com/google/doclava/parser/Java.g:373:9: normalClassDeclaration 1566 { 1567 dbg.location(373,9); 1568 pushFollow(FOLLOW_normalClassDeclaration_in_classDeclaration659); 1569 normalClassDeclaration(); 1570 1571 state._fsp--; 1572 if (state.failed) return ; 1573 1574 } 1575 break; 1576 case 2 : 1577 dbg.enterAlt(2); 1578 1579 // src/com/google/doclava/parser/Java.g:374:9: enumDeclaration 1580 { 1581 dbg.location(374,9); 1582 pushFollow(FOLLOW_enumDeclaration_in_classDeclaration669); 1583 enumDeclaration(); 1584 1585 state._fsp--; 1586 if (state.failed) return ; 1587 1588 } 1589 break; 1590 1591 } 1592 } 1593 catch (RecognitionException re) { 1594 reportError(re); 1595 recover(input,re); 1596 } 1597 finally { 1598 if ( state.backtracking>0 ) { memoize(input, 9, classDeclaration_StartIndex); } 1599 } 1600 dbg.location(375, 5); 1601 1602 } 1603 finally { 1604 dbg.exitRule(getGrammarFileName(), "classDeclaration"); 1605 decRuleLevel(); 1606 if ( getRuleLevel()==0 ) {dbg.terminate();} 1607 } 1608 1609 return ; 1610 } 1611 // $ANTLR end "classDeclaration" 1612 1613 1614 // $ANTLR start "normalClassDeclaration" 1615 // src/com/google/doclava/parser/Java.g:377:1: normalClassDeclaration : modifiers 'class' IDENTIFIER ( typeParameters )? ( 'extends' type )? ( 'implements' typeList )? classBody ; 1616 public final void normalClassDeclaration() throws RecognitionException { 1617 int normalClassDeclaration_StartIndex = input.index(); 1618 try { dbg.enterRule(getGrammarFileName(), "normalClassDeclaration"); 1619 if ( getRuleLevel()==0 ) {dbg.commence();} 1620 incRuleLevel(); 1621 dbg.location(377, 1); 1622 1623 try { 1624 if ( state.backtracking>0 && alreadyParsedRule(input, 10) ) { return ; } 1625 // src/com/google/doclava/parser/Java.g:378:5: ( modifiers 'class' IDENTIFIER ( typeParameters )? ( 'extends' type )? ( 'implements' typeList )? classBody ) 1626 dbg.enterAlt(1); 1627 1628 // src/com/google/doclava/parser/Java.g:378:9: modifiers 'class' IDENTIFIER ( typeParameters )? ( 'extends' type )? ( 'implements' typeList )? classBody 1629 { 1630 dbg.location(378,9); 1631 pushFollow(FOLLOW_modifiers_in_normalClassDeclaration688); 1632 modifiers(); 1633 1634 state._fsp--; 1635 if (state.failed) return ; 1636 dbg.location(378,20); 1637 match(input,CLASS,FOLLOW_CLASS_in_normalClassDeclaration691); if (state.failed) return ; 1638 dbg.location(378,28); 1639 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_normalClassDeclaration693); if (state.failed) return ; 1640 dbg.location(379,9); 1641 // src/com/google/doclava/parser/Java.g:379:9: ( typeParameters )? 1642 int alt16=2; 1643 try { dbg.enterSubRule(16); 1644 try { dbg.enterDecision(16, decisionCanBacktrack[16]); 1645 1646 int LA16_0 = input.LA(1); 1647 1648 if ( (LA16_0==LT) ) { 1649 alt16=1; 1650 } 1651 } finally {dbg.exitDecision(16);} 1652 1653 switch (alt16) { 1654 case 1 : 1655 dbg.enterAlt(1); 1656 1657 // src/com/google/doclava/parser/Java.g:379:10: typeParameters 1658 { 1659 dbg.location(379,10); 1660 pushFollow(FOLLOW_typeParameters_in_normalClassDeclaration704); 1661 typeParameters(); 1662 1663 state._fsp--; 1664 if (state.failed) return ; 1665 1666 } 1667 break; 1668 1669 } 1670 } finally {dbg.exitSubRule(16);} 1671 1672 dbg.location(381,9); 1673 // src/com/google/doclava/parser/Java.g:381:9: ( 'extends' type )? 1674 int alt17=2; 1675 try { dbg.enterSubRule(17); 1676 try { dbg.enterDecision(17, decisionCanBacktrack[17]); 1677 1678 int LA17_0 = input.LA(1); 1679 1680 if ( (LA17_0==EXTENDS) ) { 1681 alt17=1; 1682 } 1683 } finally {dbg.exitDecision(17);} 1684 1685 switch (alt17) { 1686 case 1 : 1687 dbg.enterAlt(1); 1688 1689 // src/com/google/doclava/parser/Java.g:381:10: 'extends' type 1690 { 1691 dbg.location(381,10); 1692 match(input,EXTENDS,FOLLOW_EXTENDS_in_normalClassDeclaration726); if (state.failed) return ; 1693 dbg.location(381,20); 1694 pushFollow(FOLLOW_type_in_normalClassDeclaration728); 1695 type(); 1696 1697 state._fsp--; 1698 if (state.failed) return ; 1699 1700 } 1701 break; 1702 1703 } 1704 } finally {dbg.exitSubRule(17);} 1705 1706 dbg.location(383,9); 1707 // src/com/google/doclava/parser/Java.g:383:9: ( 'implements' typeList )? 1708 int alt18=2; 1709 try { dbg.enterSubRule(18); 1710 try { dbg.enterDecision(18, decisionCanBacktrack[18]); 1711 1712 int LA18_0 = input.LA(1); 1713 1714 if ( (LA18_0==IMPLEMENTS) ) { 1715 alt18=1; 1716 } 1717 } finally {dbg.exitDecision(18);} 1718 1719 switch (alt18) { 1720 case 1 : 1721 dbg.enterAlt(1); 1722 1723 // src/com/google/doclava/parser/Java.g:383:10: 'implements' typeList 1724 { 1725 dbg.location(383,10); 1726 match(input,IMPLEMENTS,FOLLOW_IMPLEMENTS_in_normalClassDeclaration750); if (state.failed) return ; 1727 dbg.location(383,23); 1728 pushFollow(FOLLOW_typeList_in_normalClassDeclaration752); 1729 typeList(); 1730 1731 state._fsp--; 1732 if (state.failed) return ; 1733 1734 } 1735 break; 1736 1737 } 1738 } finally {dbg.exitSubRule(18);} 1739 1740 dbg.location(385,9); 1741 pushFollow(FOLLOW_classBody_in_normalClassDeclaration773); 1742 classBody(); 1743 1744 state._fsp--; 1745 if (state.failed) return ; 1746 1747 } 1748 1749 } 1750 catch (RecognitionException re) { 1751 reportError(re); 1752 recover(input,re); 1753 } 1754 finally { 1755 if ( state.backtracking>0 ) { memoize(input, 10, normalClassDeclaration_StartIndex); } 1756 } 1757 dbg.location(386, 5); 1758 1759 } 1760 finally { 1761 dbg.exitRule(getGrammarFileName(), "normalClassDeclaration"); 1762 decRuleLevel(); 1763 if ( getRuleLevel()==0 ) {dbg.terminate();} 1764 } 1765 1766 return ; 1767 } 1768 // $ANTLR end "normalClassDeclaration" 1769 1770 1771 // $ANTLR start "typeParameters" 1772 // src/com/google/doclava/parser/Java.g:389:1: typeParameters : '<' typeParameter ( ',' typeParameter )* '>' ; 1773 public final void typeParameters() throws RecognitionException { 1774 int typeParameters_StartIndex = input.index(); 1775 try { dbg.enterRule(getGrammarFileName(), "typeParameters"); 1776 if ( getRuleLevel()==0 ) {dbg.commence();} 1777 incRuleLevel(); 1778 dbg.location(389, 1); 1779 1780 try { 1781 if ( state.backtracking>0 && alreadyParsedRule(input, 11) ) { return ; } 1782 // src/com/google/doclava/parser/Java.g:390:5: ( '<' typeParameter ( ',' typeParameter )* '>' ) 1783 dbg.enterAlt(1); 1784 1785 // src/com/google/doclava/parser/Java.g:390:9: '<' typeParameter ( ',' typeParameter )* '>' 1786 { 1787 dbg.location(390,9); 1788 match(input,LT,FOLLOW_LT_in_typeParameters793); if (state.failed) return ; 1789 dbg.location(391,13); 1790 pushFollow(FOLLOW_typeParameter_in_typeParameters807); 1791 typeParameter(); 1792 1793 state._fsp--; 1794 if (state.failed) return ; 1795 dbg.location(392,13); 1796 // src/com/google/doclava/parser/Java.g:392:13: ( ',' typeParameter )* 1797 try { dbg.enterSubRule(19); 1798 1799 loop19: 1800 do { 1801 int alt19=2; 1802 try { dbg.enterDecision(19, decisionCanBacktrack[19]); 1803 1804 int LA19_0 = input.LA(1); 1805 1806 if ( (LA19_0==COMMA) ) { 1807 alt19=1; 1808 } 1809 1810 1811 } finally {dbg.exitDecision(19);} 1812 1813 switch (alt19) { 1814 case 1 : 1815 dbg.enterAlt(1); 1816 1817 // src/com/google/doclava/parser/Java.g:392:14: ',' typeParameter 1818 { 1819 dbg.location(392,14); 1820 match(input,COMMA,FOLLOW_COMMA_in_typeParameters822); if (state.failed) return ; 1821 dbg.location(392,18); 1822 pushFollow(FOLLOW_typeParameter_in_typeParameters824); 1823 typeParameter(); 1824 1825 state._fsp--; 1826 if (state.failed) return ; 1827 1828 } 1829 break; 1830 1831 default : 1832 break loop19; 1833 } 1834 } while (true); 1835 } finally {dbg.exitSubRule(19);} 1836 1837 dbg.location(394,9); 1838 match(input,GT,FOLLOW_GT_in_typeParameters849); if (state.failed) return ; 1839 1840 } 1841 1842 } 1843 catch (RecognitionException re) { 1844 reportError(re); 1845 recover(input,re); 1846 } 1847 finally { 1848 if ( state.backtracking>0 ) { memoize(input, 11, typeParameters_StartIndex); } 1849 } 1850 dbg.location(395, 5); 1851 1852 } 1853 finally { 1854 dbg.exitRule(getGrammarFileName(), "typeParameters"); 1855 decRuleLevel(); 1856 if ( getRuleLevel()==0 ) {dbg.terminate();} 1857 } 1858 1859 return ; 1860 } 1861 // $ANTLR end "typeParameters" 1862 1863 1864 // $ANTLR start "typeParameter" 1865 // src/com/google/doclava/parser/Java.g:397:1: typeParameter : IDENTIFIER ( 'extends' typeBound )? ; 1866 public final void typeParameter() throws RecognitionException { 1867 int typeParameter_StartIndex = input.index(); 1868 try { dbg.enterRule(getGrammarFileName(), "typeParameter"); 1869 if ( getRuleLevel()==0 ) {dbg.commence();} 1870 incRuleLevel(); 1871 dbg.location(397, 1); 1872 1873 try { 1874 if ( state.backtracking>0 && alreadyParsedRule(input, 12) ) { return ; } 1875 // src/com/google/doclava/parser/Java.g:398:5: ( IDENTIFIER ( 'extends' typeBound )? ) 1876 dbg.enterAlt(1); 1877 1878 // src/com/google/doclava/parser/Java.g:398:9: IDENTIFIER ( 'extends' typeBound )? 1879 { 1880 dbg.location(398,9); 1881 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_typeParameter868); if (state.failed) return ; 1882 dbg.location(399,9); 1883 // src/com/google/doclava/parser/Java.g:399:9: ( 'extends' typeBound )? 1884 int alt20=2; 1885 try { dbg.enterSubRule(20); 1886 try { dbg.enterDecision(20, decisionCanBacktrack[20]); 1887 1888 int LA20_0 = input.LA(1); 1889 1890 if ( (LA20_0==EXTENDS) ) { 1891 alt20=1; 1892 } 1893 } finally {dbg.exitDecision(20);} 1894 1895 switch (alt20) { 1896 case 1 : 1897 dbg.enterAlt(1); 1898 1899 // src/com/google/doclava/parser/Java.g:399:10: 'extends' typeBound 1900 { 1901 dbg.location(399,10); 1902 match(input,EXTENDS,FOLLOW_EXTENDS_in_typeParameter879); if (state.failed) return ; 1903 dbg.location(399,20); 1904 pushFollow(FOLLOW_typeBound_in_typeParameter881); 1905 typeBound(); 1906 1907 state._fsp--; 1908 if (state.failed) return ; 1909 1910 } 1911 break; 1912 1913 } 1914 } finally {dbg.exitSubRule(20);} 1915 1916 1917 } 1918 1919 } 1920 catch (RecognitionException re) { 1921 reportError(re); 1922 recover(input,re); 1923 } 1924 finally { 1925 if ( state.backtracking>0 ) { memoize(input, 12, typeParameter_StartIndex); } 1926 } 1927 dbg.location(401, 5); 1928 1929 } 1930 finally { 1931 dbg.exitRule(getGrammarFileName(), "typeParameter"); 1932 decRuleLevel(); 1933 if ( getRuleLevel()==0 ) {dbg.terminate();} 1934 } 1935 1936 return ; 1937 } 1938 // $ANTLR end "typeParameter" 1939 1940 1941 // $ANTLR start "typeBound" 1942 // src/com/google/doclava/parser/Java.g:404:1: typeBound : type ( '&' type )* ; 1943 public final void typeBound() throws RecognitionException { 1944 int typeBound_StartIndex = input.index(); 1945 try { dbg.enterRule(getGrammarFileName(), "typeBound"); 1946 if ( getRuleLevel()==0 ) {dbg.commence();} 1947 incRuleLevel(); 1948 dbg.location(404, 1); 1949 1950 try { 1951 if ( state.backtracking>0 && alreadyParsedRule(input, 13) ) { return ; } 1952 // src/com/google/doclava/parser/Java.g:405:5: ( type ( '&' type )* ) 1953 dbg.enterAlt(1); 1954 1955 // src/com/google/doclava/parser/Java.g:405:9: type ( '&' type )* 1956 { 1957 dbg.location(405,9); 1958 pushFollow(FOLLOW_type_in_typeBound912); 1959 type(); 1960 1961 state._fsp--; 1962 if (state.failed) return ; 1963 dbg.location(406,9); 1964 // src/com/google/doclava/parser/Java.g:406:9: ( '&' type )* 1965 try { dbg.enterSubRule(21); 1966 1967 loop21: 1968 do { 1969 int alt21=2; 1970 try { dbg.enterDecision(21, decisionCanBacktrack[21]); 1971 1972 int LA21_0 = input.LA(1); 1973 1974 if ( (LA21_0==AMP) ) { 1975 alt21=1; 1976 } 1977 1978 1979 } finally {dbg.exitDecision(21);} 1980 1981 switch (alt21) { 1982 case 1 : 1983 dbg.enterAlt(1); 1984 1985 // src/com/google/doclava/parser/Java.g:406:10: '&' type 1986 { 1987 dbg.location(406,10); 1988 match(input,AMP,FOLLOW_AMP_in_typeBound923); if (state.failed) return ; 1989 dbg.location(406,14); 1990 pushFollow(FOLLOW_type_in_typeBound925); 1991 type(); 1992 1993 state._fsp--; 1994 if (state.failed) return ; 1995 1996 } 1997 break; 1998 1999 default : 2000 break loop21; 2001 } 2002 } while (true); 2003 } finally {dbg.exitSubRule(21);} 2004 2005 2006 } 2007 2008 } 2009 catch (RecognitionException re) { 2010 reportError(re); 2011 recover(input,re); 2012 } 2013 finally { 2014 if ( state.backtracking>0 ) { memoize(input, 13, typeBound_StartIndex); } 2015 } 2016 dbg.location(408, 5); 2017 2018 } 2019 finally { 2020 dbg.exitRule(getGrammarFileName(), "typeBound"); 2021 decRuleLevel(); 2022 if ( getRuleLevel()==0 ) {dbg.terminate();} 2023 } 2024 2025 return ; 2026 } 2027 // $ANTLR end "typeBound" 2028 2029 2030 // $ANTLR start "enumDeclaration" 2031 // src/com/google/doclava/parser/Java.g:411:1: enumDeclaration : modifiers ( 'enum' ) IDENTIFIER ( 'implements' typeList )? enumBody ; 2032 public final void enumDeclaration() throws RecognitionException { 2033 int enumDeclaration_StartIndex = input.index(); 2034 try { dbg.enterRule(getGrammarFileName(), "enumDeclaration"); 2035 if ( getRuleLevel()==0 ) {dbg.commence();} 2036 incRuleLevel(); 2037 dbg.location(411, 1); 2038 2039 try { 2040 if ( state.backtracking>0 && alreadyParsedRule(input, 14) ) { return ; } 2041 // src/com/google/doclava/parser/Java.g:412:5: ( modifiers ( 'enum' ) IDENTIFIER ( 'implements' typeList )? enumBody ) 2042 dbg.enterAlt(1); 2043 2044 // src/com/google/doclava/parser/Java.g:412:9: modifiers ( 'enum' ) IDENTIFIER ( 'implements' typeList )? enumBody 2045 { 2046 dbg.location(412,9); 2047 pushFollow(FOLLOW_modifiers_in_enumDeclaration956); 2048 modifiers(); 2049 2050 state._fsp--; 2051 if (state.failed) return ; 2052 dbg.location(413,9); 2053 // src/com/google/doclava/parser/Java.g:413:9: ( 'enum' ) 2054 dbg.enterAlt(1); 2055 2056 // src/com/google/doclava/parser/Java.g:413:10: 'enum' 2057 { 2058 dbg.location(413,10); 2059 match(input,ENUM,FOLLOW_ENUM_in_enumDeclaration967); if (state.failed) return ; 2060 2061 } 2062 2063 dbg.location(415,9); 2064 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_enumDeclaration987); if (state.failed) return ; 2065 dbg.location(416,9); 2066 // src/com/google/doclava/parser/Java.g:416:9: ( 'implements' typeList )? 2067 int alt22=2; 2068 try { dbg.enterSubRule(22); 2069 try { dbg.enterDecision(22, decisionCanBacktrack[22]); 2070 2071 int LA22_0 = input.LA(1); 2072 2073 if ( (LA22_0==IMPLEMENTS) ) { 2074 alt22=1; 2075 } 2076 } finally {dbg.exitDecision(22);} 2077 2078 switch (alt22) { 2079 case 1 : 2080 dbg.enterAlt(1); 2081 2082 // src/com/google/doclava/parser/Java.g:416:10: 'implements' typeList 2083 { 2084 dbg.location(416,10); 2085 match(input,IMPLEMENTS,FOLLOW_IMPLEMENTS_in_enumDeclaration998); if (state.failed) return ; 2086 dbg.location(416,23); 2087 pushFollow(FOLLOW_typeList_in_enumDeclaration1000); 2088 typeList(); 2089 2090 state._fsp--; 2091 if (state.failed) return ; 2092 2093 } 2094 break; 2095 2096 } 2097 } finally {dbg.exitSubRule(22);} 2098 2099 dbg.location(418,9); 2100 pushFollow(FOLLOW_enumBody_in_enumDeclaration1021); 2101 enumBody(); 2102 2103 state._fsp--; 2104 if (state.failed) return ; 2105 2106 } 2107 2108 } 2109 catch (RecognitionException re) { 2110 reportError(re); 2111 recover(input,re); 2112 } 2113 finally { 2114 if ( state.backtracking>0 ) { memoize(input, 14, enumDeclaration_StartIndex); } 2115 } 2116 dbg.location(419, 5); 2117 2118 } 2119 finally { 2120 dbg.exitRule(getGrammarFileName(), "enumDeclaration"); 2121 decRuleLevel(); 2122 if ( getRuleLevel()==0 ) {dbg.terminate();} 2123 } 2124 2125 return ; 2126 } 2127 // $ANTLR end "enumDeclaration" 2128 2129 2130 // $ANTLR start "enumBody" 2131 // src/com/google/doclava/parser/Java.g:422:1: enumBody : '{' ( enumConstants )? ( ',' )? ( enumBodyDeclarations )? '}' ; 2132 public final void enumBody() throws RecognitionException { 2133 int enumBody_StartIndex = input.index(); 2134 try { dbg.enterRule(getGrammarFileName(), "enumBody"); 2135 if ( getRuleLevel()==0 ) {dbg.commence();} 2136 incRuleLevel(); 2137 dbg.location(422, 1); 2138 2139 try { 2140 if ( state.backtracking>0 && alreadyParsedRule(input, 15) ) { return ; } 2141 // src/com/google/doclava/parser/Java.g:423:5: ( '{' ( enumConstants )? ( ',' )? ( enumBodyDeclarations )? '}' ) 2142 dbg.enterAlt(1); 2143 2144 // src/com/google/doclava/parser/Java.g:423:9: '{' ( enumConstants )? ( ',' )? ( enumBodyDeclarations )? '}' 2145 { 2146 dbg.location(423,9); 2147 match(input,LBRACE,FOLLOW_LBRACE_in_enumBody1041); if (state.failed) return ; 2148 dbg.location(424,9); 2149 // src/com/google/doclava/parser/Java.g:424:9: ( enumConstants )? 2150 int alt23=2; 2151 try { dbg.enterSubRule(23); 2152 try { dbg.enterDecision(23, decisionCanBacktrack[23]); 2153 2154 int LA23_0 = input.LA(1); 2155 2156 if ( (LA23_0==IDENTIFIER||LA23_0==MONKEYS_AT) ) { 2157 alt23=1; 2158 } 2159 } finally {dbg.exitDecision(23);} 2160 2161 switch (alt23) { 2162 case 1 : 2163 dbg.enterAlt(1); 2164 2165 // src/com/google/doclava/parser/Java.g:424:10: enumConstants 2166 { 2167 dbg.location(424,10); 2168 pushFollow(FOLLOW_enumConstants_in_enumBody1052); 2169 enumConstants(); 2170 2171 state._fsp--; 2172 if (state.failed) return ; 2173 2174 } 2175 break; 2176 2177 } 2178 } finally {dbg.exitSubRule(23);} 2179 2180 dbg.location(426,9); 2181 // src/com/google/doclava/parser/Java.g:426:9: ( ',' )? 2182 int alt24=2; 2183 try { dbg.enterSubRule(24); 2184 try { dbg.enterDecision(24, decisionCanBacktrack[24]); 2185 2186 int LA24_0 = input.LA(1); 2187 2188 if ( (LA24_0==COMMA) ) { 2189 alt24=1; 2190 } 2191 } finally {dbg.exitDecision(24);} 2192 2193 switch (alt24) { 2194 case 1 : 2195 dbg.enterAlt(1); 2196 2197 // src/com/google/doclava/parser/Java.g:0:0: ',' 2198 { 2199 dbg.location(426,9); 2200 match(input,COMMA,FOLLOW_COMMA_in_enumBody1073); if (state.failed) return ; 2201 2202 } 2203 break; 2204 2205 } 2206 } finally {dbg.exitSubRule(24);} 2207 2208 dbg.location(427,9); 2209 // src/com/google/doclava/parser/Java.g:427:9: ( enumBodyDeclarations )? 2210 int alt25=2; 2211 try { dbg.enterSubRule(25); 2212 try { dbg.enterDecision(25, decisionCanBacktrack[25]); 2213 2214 int LA25_0 = input.LA(1); 2215 2216 if ( (LA25_0==SEMI) ) { 2217 alt25=1; 2218 } 2219 } finally {dbg.exitDecision(25);} 2220 2221 switch (alt25) { 2222 case 1 : 2223 dbg.enterAlt(1); 2224 2225 // src/com/google/doclava/parser/Java.g:427:10: enumBodyDeclarations 2226 { 2227 dbg.location(427,10); 2228 pushFollow(FOLLOW_enumBodyDeclarations_in_enumBody1085); 2229 enumBodyDeclarations(); 2230 2231 state._fsp--; 2232 if (state.failed) return ; 2233 2234 } 2235 break; 2236 2237 } 2238 } finally {dbg.exitSubRule(25);} 2239 2240 dbg.location(429,9); 2241 match(input,RBRACE,FOLLOW_RBRACE_in_enumBody1106); if (state.failed) return ; 2242 2243 } 2244 2245 } 2246 catch (RecognitionException re) { 2247 reportError(re); 2248 recover(input,re); 2249 } 2250 finally { 2251 if ( state.backtracking>0 ) { memoize(input, 15, enumBody_StartIndex); } 2252 } 2253 dbg.location(430, 5); 2254 2255 } 2256 finally { 2257 dbg.exitRule(getGrammarFileName(), "enumBody"); 2258 decRuleLevel(); 2259 if ( getRuleLevel()==0 ) {dbg.terminate();} 2260 } 2261 2262 return ; 2263 } 2264 // $ANTLR end "enumBody" 2265 2266 2267 // $ANTLR start "enumConstants" 2268 // src/com/google/doclava/parser/Java.g:432:1: enumConstants : enumConstant ( ',' enumConstant )* ; 2269 public final void enumConstants() throws RecognitionException { 2270 int enumConstants_StartIndex = input.index(); 2271 try { dbg.enterRule(getGrammarFileName(), "enumConstants"); 2272 if ( getRuleLevel()==0 ) {dbg.commence();} 2273 incRuleLevel(); 2274 dbg.location(432, 1); 2275 2276 try { 2277 if ( state.backtracking>0 && alreadyParsedRule(input, 16) ) { return ; } 2278 // src/com/google/doclava/parser/Java.g:433:5: ( enumConstant ( ',' enumConstant )* ) 2279 dbg.enterAlt(1); 2280 2281 // src/com/google/doclava/parser/Java.g:433:9: enumConstant ( ',' enumConstant )* 2282 { 2283 dbg.location(433,9); 2284 pushFollow(FOLLOW_enumConstant_in_enumConstants1125); 2285 enumConstant(); 2286 2287 state._fsp--; 2288 if (state.failed) return ; 2289 dbg.location(434,9); 2290 // src/com/google/doclava/parser/Java.g:434:9: ( ',' enumConstant )* 2291 try { dbg.enterSubRule(26); 2292 2293 loop26: 2294 do { 2295 int alt26=2; 2296 try { dbg.enterDecision(26, decisionCanBacktrack[26]); 2297 2298 int LA26_0 = input.LA(1); 2299 2300 if ( (LA26_0==COMMA) ) { 2301 int LA26_1 = input.LA(2); 2302 2303 if ( (LA26_1==IDENTIFIER||LA26_1==MONKEYS_AT) ) { 2304 alt26=1; 2305 } 2306 2307 2308 } 2309 2310 2311 } finally {dbg.exitDecision(26);} 2312 2313 switch (alt26) { 2314 case 1 : 2315 dbg.enterAlt(1); 2316 2317 // src/com/google/doclava/parser/Java.g:434:10: ',' enumConstant 2318 { 2319 dbg.location(434,10); 2320 match(input,COMMA,FOLLOW_COMMA_in_enumConstants1136); if (state.failed) return ; 2321 dbg.location(434,14); 2322 pushFollow(FOLLOW_enumConstant_in_enumConstants1138); 2323 enumConstant(); 2324 2325 state._fsp--; 2326 if (state.failed) return ; 2327 2328 } 2329 break; 2330 2331 default : 2332 break loop26; 2333 } 2334 } while (true); 2335 } finally {dbg.exitSubRule(26);} 2336 2337 2338 } 2339 2340 } 2341 catch (RecognitionException re) { 2342 reportError(re); 2343 recover(input,re); 2344 } 2345 finally { 2346 if ( state.backtracking>0 ) { memoize(input, 16, enumConstants_StartIndex); } 2347 } 2348 dbg.location(436, 5); 2349 2350 } 2351 finally { 2352 dbg.exitRule(getGrammarFileName(), "enumConstants"); 2353 decRuleLevel(); 2354 if ( getRuleLevel()==0 ) {dbg.terminate();} 2355 } 2356 2357 return ; 2358 } 2359 // $ANTLR end "enumConstants" 2360 2361 2362 // $ANTLR start "enumConstant" 2363 // src/com/google/doclava/parser/Java.g:438:1: enumConstant : ( annotations )? IDENTIFIER ( arguments )? ( classBody )? ; 2364 public final void enumConstant() throws RecognitionException { 2365 int enumConstant_StartIndex = input.index(); 2366 try { dbg.enterRule(getGrammarFileName(), "enumConstant"); 2367 if ( getRuleLevel()==0 ) {dbg.commence();} 2368 incRuleLevel(); 2369 dbg.location(438, 1); 2370 2371 try { 2372 if ( state.backtracking>0 && alreadyParsedRule(input, 17) ) { return ; } 2373 // src/com/google/doclava/parser/Java.g:443:5: ( ( annotations )? IDENTIFIER ( arguments )? ( classBody )? ) 2374 dbg.enterAlt(1); 2375 2376 // src/com/google/doclava/parser/Java.g:443:9: ( annotations )? IDENTIFIER ( arguments )? ( classBody )? 2377 { 2378 dbg.location(443,9); 2379 // src/com/google/doclava/parser/Java.g:443:9: ( annotations )? 2380 int alt27=2; 2381 try { dbg.enterSubRule(27); 2382 try { dbg.enterDecision(27, decisionCanBacktrack[27]); 2383 2384 int LA27_0 = input.LA(1); 2385 2386 if ( (LA27_0==MONKEYS_AT) ) { 2387 alt27=1; 2388 } 2389 } finally {dbg.exitDecision(27);} 2390 2391 switch (alt27) { 2392 case 1 : 2393 dbg.enterAlt(1); 2394 2395 // src/com/google/doclava/parser/Java.g:443:10: annotations 2396 { 2397 dbg.location(443,10); 2398 pushFollow(FOLLOW_annotations_in_enumConstant1171); 2399 annotations(); 2400 2401 state._fsp--; 2402 if (state.failed) return ; 2403 2404 } 2405 break; 2406 2407 } 2408 } finally {dbg.exitSubRule(27);} 2409 2410 dbg.location(445,9); 2411 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_enumConstant1192); if (state.failed) return ; 2412 dbg.location(446,9); 2413 // src/com/google/doclava/parser/Java.g:446:9: ( arguments )? 2414 int alt28=2; 2415 try { dbg.enterSubRule(28); 2416 try { dbg.enterDecision(28, decisionCanBacktrack[28]); 2417 2418 int LA28_0 = input.LA(1); 2419 2420 if ( (LA28_0==LPAREN) ) { 2421 alt28=1; 2422 } 2423 } finally {dbg.exitDecision(28);} 2424 2425 switch (alt28) { 2426 case 1 : 2427 dbg.enterAlt(1); 2428 2429 // src/com/google/doclava/parser/Java.g:446:10: arguments 2430 { 2431 dbg.location(446,10); 2432 pushFollow(FOLLOW_arguments_in_enumConstant1203); 2433 arguments(); 2434 2435 state._fsp--; 2436 if (state.failed) return ; 2437 2438 } 2439 break; 2440 2441 } 2442 } finally {dbg.exitSubRule(28);} 2443 2444 dbg.location(448,9); 2445 // src/com/google/doclava/parser/Java.g:448:9: ( classBody )? 2446 int alt29=2; 2447 try { dbg.enterSubRule(29); 2448 try { dbg.enterDecision(29, decisionCanBacktrack[29]); 2449 2450 int LA29_0 = input.LA(1); 2451 2452 if ( (LA29_0==LBRACE) ) { 2453 alt29=1; 2454 } 2455 } finally {dbg.exitDecision(29);} 2456 2457 switch (alt29) { 2458 case 1 : 2459 dbg.enterAlt(1); 2460 2461 // src/com/google/doclava/parser/Java.g:448:10: classBody 2462 { 2463 dbg.location(448,10); 2464 pushFollow(FOLLOW_classBody_in_enumConstant1225); 2465 classBody(); 2466 2467 state._fsp--; 2468 if (state.failed) return ; 2469 2470 } 2471 break; 2472 2473 } 2474 } finally {dbg.exitSubRule(29);} 2475 2476 2477 } 2478 2479 } 2480 catch (RecognitionException re) { 2481 reportError(re); 2482 recover(input,re); 2483 } 2484 finally { 2485 if ( state.backtracking>0 ) { memoize(input, 17, enumConstant_StartIndex); } 2486 } 2487 dbg.location(452, 5); 2488 2489 } 2490 finally { 2491 dbg.exitRule(getGrammarFileName(), "enumConstant"); 2492 decRuleLevel(); 2493 if ( getRuleLevel()==0 ) {dbg.terminate();} 2494 } 2495 2496 return ; 2497 } 2498 // $ANTLR end "enumConstant" 2499 2500 2501 // $ANTLR start "enumBodyDeclarations" 2502 // src/com/google/doclava/parser/Java.g:454:1: enumBodyDeclarations : ';' ( classBodyDeclaration )* ; 2503 public final void enumBodyDeclarations() throws RecognitionException { 2504 int enumBodyDeclarations_StartIndex = input.index(); 2505 try { dbg.enterRule(getGrammarFileName(), "enumBodyDeclarations"); 2506 if ( getRuleLevel()==0 ) {dbg.commence();} 2507 incRuleLevel(); 2508 dbg.location(454, 1); 2509 2510 try { 2511 if ( state.backtracking>0 && alreadyParsedRule(input, 18) ) { return ; } 2512 // src/com/google/doclava/parser/Java.g:455:5: ( ';' ( classBodyDeclaration )* ) 2513 dbg.enterAlt(1); 2514 2515 // src/com/google/doclava/parser/Java.g:455:9: ';' ( classBodyDeclaration )* 2516 { 2517 dbg.location(455,9); 2518 match(input,SEMI,FOLLOW_SEMI_in_enumBodyDeclarations1265); if (state.failed) return ; 2519 dbg.location(456,9); 2520 // src/com/google/doclava/parser/Java.g:456:9: ( classBodyDeclaration )* 2521 try { dbg.enterSubRule(30); 2522 2523 loop30: 2524 do { 2525 int alt30=2; 2526 try { dbg.enterDecision(30, decisionCanBacktrack[30]); 2527 2528 int LA30_0 = input.LA(1); 2529 2530 if ( (LA30_0==IDENTIFIER||LA30_0==ABSTRACT||LA30_0==BOOLEAN||LA30_0==BYTE||(LA30_0>=CHAR && LA30_0<=CLASS)||LA30_0==DOUBLE||LA30_0==ENUM||LA30_0==FINAL||LA30_0==FLOAT||(LA30_0>=INT && LA30_0<=NATIVE)||(LA30_0>=PRIVATE && LA30_0<=PUBLIC)||(LA30_0>=SHORT && LA30_0<=STRICTFP)||LA30_0==SYNCHRONIZED||LA30_0==TRANSIENT||(LA30_0>=VOID && LA30_0<=VOLATILE)||LA30_0==LBRACE||LA30_0==SEMI||LA30_0==MONKEYS_AT||LA30_0==LT) ) { 2531 alt30=1; 2532 } 2533 2534 2535 } finally {dbg.exitDecision(30);} 2536 2537 switch (alt30) { 2538 case 1 : 2539 dbg.enterAlt(1); 2540 2541 // src/com/google/doclava/parser/Java.g:456:10: classBodyDeclaration 2542 { 2543 dbg.location(456,10); 2544 pushFollow(FOLLOW_classBodyDeclaration_in_enumBodyDeclarations1276); 2545 classBodyDeclaration(); 2546 2547 state._fsp--; 2548 if (state.failed) return ; 2549 2550 } 2551 break; 2552 2553 default : 2554 break loop30; 2555 } 2556 } while (true); 2557 } finally {dbg.exitSubRule(30);} 2558 2559 2560 } 2561 2562 } 2563 catch (RecognitionException re) { 2564 reportError(re); 2565 recover(input,re); 2566 } 2567 finally { 2568 if ( state.backtracking>0 ) { memoize(input, 18, enumBodyDeclarations_StartIndex); } 2569 } 2570 dbg.location(458, 5); 2571 2572 } 2573 finally { 2574 dbg.exitRule(getGrammarFileName(), "enumBodyDeclarations"); 2575 decRuleLevel(); 2576 if ( getRuleLevel()==0 ) {dbg.terminate();} 2577 } 2578 2579 return ; 2580 } 2581 // $ANTLR end "enumBodyDeclarations" 2582 2583 2584 // $ANTLR start "interfaceDeclaration" 2585 // src/com/google/doclava/parser/Java.g:460:1: interfaceDeclaration : ( normalInterfaceDeclaration | annotationTypeDeclaration ); 2586 public final void interfaceDeclaration() throws RecognitionException { 2587 int interfaceDeclaration_StartIndex = input.index(); 2588 try { dbg.enterRule(getGrammarFileName(), "interfaceDeclaration"); 2589 if ( getRuleLevel()==0 ) {dbg.commence();} 2590 incRuleLevel(); 2591 dbg.location(460, 1); 2592 2593 try { 2594 if ( state.backtracking>0 && alreadyParsedRule(input, 19) ) { return ; } 2595 // src/com/google/doclava/parser/Java.g:461:5: ( normalInterfaceDeclaration | annotationTypeDeclaration ) 2596 int alt31=2; 2597 try { dbg.enterDecision(31, decisionCanBacktrack[31]); 2598 2599 try { 2600 isCyclicDecision = true; 2601 alt31 = dfa31.predict(input); 2602 } 2603 catch (NoViableAltException nvae) { 2604 dbg.recognitionException(nvae); 2605 throw nvae; 2606 } 2607 } finally {dbg.exitDecision(31);} 2608 2609 switch (alt31) { 2610 case 1 : 2611 dbg.enterAlt(1); 2612 2613 // src/com/google/doclava/parser/Java.g:461:9: normalInterfaceDeclaration 2614 { 2615 dbg.location(461,9); 2616 pushFollow(FOLLOW_normalInterfaceDeclaration_in_interfaceDeclaration1306); 2617 normalInterfaceDeclaration(); 2618 2619 state._fsp--; 2620 if (state.failed) return ; 2621 2622 } 2623 break; 2624 case 2 : 2625 dbg.enterAlt(2); 2626 2627 // src/com/google/doclava/parser/Java.g:462:9: annotationTypeDeclaration 2628 { 2629 dbg.location(462,9); 2630 pushFollow(FOLLOW_annotationTypeDeclaration_in_interfaceDeclaration1316); 2631 annotationTypeDeclaration(); 2632 2633 state._fsp--; 2634 if (state.failed) return ; 2635 2636 } 2637 break; 2638 2639 } 2640 } 2641 catch (RecognitionException re) { 2642 reportError(re); 2643 recover(input,re); 2644 } 2645 finally { 2646 if ( state.backtracking>0 ) { memoize(input, 19, interfaceDeclaration_StartIndex); } 2647 } 2648 dbg.location(463, 5); 2649 2650 } 2651 finally { 2652 dbg.exitRule(getGrammarFileName(), "interfaceDeclaration"); 2653 decRuleLevel(); 2654 if ( getRuleLevel()==0 ) {dbg.terminate();} 2655 } 2656 2657 return ; 2658 } 2659 // $ANTLR end "interfaceDeclaration" 2660 2661 2662 // $ANTLR start "normalInterfaceDeclaration" 2663 // src/com/google/doclava/parser/Java.g:465:1: normalInterfaceDeclaration : modifiers 'interface' IDENTIFIER ( typeParameters )? ( 'extends' typeList )? interfaceBody ; 2664 public final void normalInterfaceDeclaration() throws RecognitionException { 2665 int normalInterfaceDeclaration_StartIndex = input.index(); 2666 try { dbg.enterRule(getGrammarFileName(), "normalInterfaceDeclaration"); 2667 if ( getRuleLevel()==0 ) {dbg.commence();} 2668 incRuleLevel(); 2669 dbg.location(465, 1); 2670 2671 try { 2672 if ( state.backtracking>0 && alreadyParsedRule(input, 20) ) { return ; } 2673 // src/com/google/doclava/parser/Java.g:466:5: ( modifiers 'interface' IDENTIFIER ( typeParameters )? ( 'extends' typeList )? interfaceBody ) 2674 dbg.enterAlt(1); 2675 2676 // src/com/google/doclava/parser/Java.g:466:9: modifiers 'interface' IDENTIFIER ( typeParameters )? ( 'extends' typeList )? interfaceBody 2677 { 2678 dbg.location(466,9); 2679 pushFollow(FOLLOW_modifiers_in_normalInterfaceDeclaration1335); 2680 modifiers(); 2681 2682 state._fsp--; 2683 if (state.failed) return ; 2684 dbg.location(466,19); 2685 match(input,INTERFACE,FOLLOW_INTERFACE_in_normalInterfaceDeclaration1337); if (state.failed) return ; 2686 dbg.location(466,31); 2687 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_normalInterfaceDeclaration1339); if (state.failed) return ; 2688 dbg.location(467,9); 2689 // src/com/google/doclava/parser/Java.g:467:9: ( typeParameters )? 2690 int alt32=2; 2691 try { dbg.enterSubRule(32); 2692 try { dbg.enterDecision(32, decisionCanBacktrack[32]); 2693 2694 int LA32_0 = input.LA(1); 2695 2696 if ( (LA32_0==LT) ) { 2697 alt32=1; 2698 } 2699 } finally {dbg.exitDecision(32);} 2700 2701 switch (alt32) { 2702 case 1 : 2703 dbg.enterAlt(1); 2704 2705 // src/com/google/doclava/parser/Java.g:467:10: typeParameters 2706 { 2707 dbg.location(467,10); 2708 pushFollow(FOLLOW_typeParameters_in_normalInterfaceDeclaration1350); 2709 typeParameters(); 2710 2711 state._fsp--; 2712 if (state.failed) return ; 2713 2714 } 2715 break; 2716 2717 } 2718 } finally {dbg.exitSubRule(32);} 2719 2720 dbg.location(469,9); 2721 // src/com/google/doclava/parser/Java.g:469:9: ( 'extends' typeList )? 2722 int alt33=2; 2723 try { dbg.enterSubRule(33); 2724 try { dbg.enterDecision(33, decisionCanBacktrack[33]); 2725 2726 int LA33_0 = input.LA(1); 2727 2728 if ( (LA33_0==EXTENDS) ) { 2729 alt33=1; 2730 } 2731 } finally {dbg.exitDecision(33);} 2732 2733 switch (alt33) { 2734 case 1 : 2735 dbg.enterAlt(1); 2736 2737 // src/com/google/doclava/parser/Java.g:469:10: 'extends' typeList 2738 { 2739 dbg.location(469,10); 2740 match(input,EXTENDS,FOLLOW_EXTENDS_in_normalInterfaceDeclaration1372); if (state.failed) return ; 2741 dbg.location(469,20); 2742 pushFollow(FOLLOW_typeList_in_normalInterfaceDeclaration1374); 2743 typeList(); 2744 2745 state._fsp--; 2746 if (state.failed) return ; 2747 2748 } 2749 break; 2750 2751 } 2752 } finally {dbg.exitSubRule(33);} 2753 2754 dbg.location(471,9); 2755 pushFollow(FOLLOW_interfaceBody_in_normalInterfaceDeclaration1395); 2756 interfaceBody(); 2757 2758 state._fsp--; 2759 if (state.failed) return ; 2760 2761 } 2762 2763 } 2764 catch (RecognitionException re) { 2765 reportError(re); 2766 recover(input,re); 2767 } 2768 finally { 2769 if ( state.backtracking>0 ) { memoize(input, 20, normalInterfaceDeclaration_StartIndex); } 2770 } 2771 dbg.location(472, 5); 2772 2773 } 2774 finally { 2775 dbg.exitRule(getGrammarFileName(), "normalInterfaceDeclaration"); 2776 decRuleLevel(); 2777 if ( getRuleLevel()==0 ) {dbg.terminate();} 2778 } 2779 2780 return ; 2781 } 2782 // $ANTLR end "normalInterfaceDeclaration" 2783 2784 2785 // $ANTLR start "typeList" 2786 // src/com/google/doclava/parser/Java.g:474:1: typeList : type ( ',' type )* ; 2787 public final void typeList() throws RecognitionException { 2788 int typeList_StartIndex = input.index(); 2789 try { dbg.enterRule(getGrammarFileName(), "typeList"); 2790 if ( getRuleLevel()==0 ) {dbg.commence();} 2791 incRuleLevel(); 2792 dbg.location(474, 1); 2793 2794 try { 2795 if ( state.backtracking>0 && alreadyParsedRule(input, 21) ) { return ; } 2796 // src/com/google/doclava/parser/Java.g:475:5: ( type ( ',' type )* ) 2797 dbg.enterAlt(1); 2798 2799 // src/com/google/doclava/parser/Java.g:475:9: type ( ',' type )* 2800 { 2801 dbg.location(475,9); 2802 pushFollow(FOLLOW_type_in_typeList1414); 2803 type(); 2804 2805 state._fsp--; 2806 if (state.failed) return ; 2807 dbg.location(476,9); 2808 // src/com/google/doclava/parser/Java.g:476:9: ( ',' type )* 2809 try { dbg.enterSubRule(34); 2810 2811 loop34: 2812 do { 2813 int alt34=2; 2814 try { dbg.enterDecision(34, decisionCanBacktrack[34]); 2815 2816 int LA34_0 = input.LA(1); 2817 2818 if ( (LA34_0==COMMA) ) { 2819 alt34=1; 2820 } 2821 2822 2823 } finally {dbg.exitDecision(34);} 2824 2825 switch (alt34) { 2826 case 1 : 2827 dbg.enterAlt(1); 2828 2829 // src/com/google/doclava/parser/Java.g:476:10: ',' type 2830 { 2831 dbg.location(476,10); 2832 match(input,COMMA,FOLLOW_COMMA_in_typeList1425); if (state.failed) return ; 2833 dbg.location(476,14); 2834 pushFollow(FOLLOW_type_in_typeList1427); 2835 type(); 2836 2837 state._fsp--; 2838 if (state.failed) return ; 2839 2840 } 2841 break; 2842 2843 default : 2844 break loop34; 2845 } 2846 } while (true); 2847 } finally {dbg.exitSubRule(34);} 2848 2849 2850 } 2851 2852 } 2853 catch (RecognitionException re) { 2854 reportError(re); 2855 recover(input,re); 2856 } 2857 finally { 2858 if ( state.backtracking>0 ) { memoize(input, 21, typeList_StartIndex); } 2859 } 2860 dbg.location(478, 5); 2861 2862 } 2863 finally { 2864 dbg.exitRule(getGrammarFileName(), "typeList"); 2865 decRuleLevel(); 2866 if ( getRuleLevel()==0 ) {dbg.terminate();} 2867 } 2868 2869 return ; 2870 } 2871 // $ANTLR end "typeList" 2872 2873 2874 // $ANTLR start "classBody" 2875 // src/com/google/doclava/parser/Java.g:480:1: classBody : '{' ( classBodyDeclaration )* '}' ; 2876 public final void classBody() throws RecognitionException { 2877 int classBody_StartIndex = input.index(); 2878 try { dbg.enterRule(getGrammarFileName(), "classBody"); 2879 if ( getRuleLevel()==0 ) {dbg.commence();} 2880 incRuleLevel(); 2881 dbg.location(480, 1); 2882 2883 try { 2884 if ( state.backtracking>0 && alreadyParsedRule(input, 22) ) { return ; } 2885 // src/com/google/doclava/parser/Java.g:481:5: ( '{' ( classBodyDeclaration )* '}' ) 2886 dbg.enterAlt(1); 2887 2888 // src/com/google/doclava/parser/Java.g:481:9: '{' ( classBodyDeclaration )* '}' 2889 { 2890 dbg.location(481,9); 2891 match(input,LBRACE,FOLLOW_LBRACE_in_classBody1457); if (state.failed) return ; 2892 dbg.location(482,9); 2893 // src/com/google/doclava/parser/Java.g:482:9: ( classBodyDeclaration )* 2894 try { dbg.enterSubRule(35); 2895 2896 loop35: 2897 do { 2898 int alt35=2; 2899 try { dbg.enterDecision(35, decisionCanBacktrack[35]); 2900 2901 int LA35_0 = input.LA(1); 2902 2903 if ( (LA35_0==IDENTIFIER||LA35_0==ABSTRACT||LA35_0==BOOLEAN||LA35_0==BYTE||(LA35_0>=CHAR && LA35_0<=CLASS)||LA35_0==DOUBLE||LA35_0==ENUM||LA35_0==FINAL||LA35_0==FLOAT||(LA35_0>=INT && LA35_0<=NATIVE)||(LA35_0>=PRIVATE && LA35_0<=PUBLIC)||(LA35_0>=SHORT && LA35_0<=STRICTFP)||LA35_0==SYNCHRONIZED||LA35_0==TRANSIENT||(LA35_0>=VOID && LA35_0<=VOLATILE)||LA35_0==LBRACE||LA35_0==SEMI||LA35_0==MONKEYS_AT||LA35_0==LT) ) { 2904 alt35=1; 2905 } 2906 2907 2908 } finally {dbg.exitDecision(35);} 2909 2910 switch (alt35) { 2911 case 1 : 2912 dbg.enterAlt(1); 2913 2914 // src/com/google/doclava/parser/Java.g:482:10: classBodyDeclaration 2915 { 2916 dbg.location(482,10); 2917 pushFollow(FOLLOW_classBodyDeclaration_in_classBody1468); 2918 classBodyDeclaration(); 2919 2920 state._fsp--; 2921 if (state.failed) return ; 2922 2923 } 2924 break; 2925 2926 default : 2927 break loop35; 2928 } 2929 } while (true); 2930 } finally {dbg.exitSubRule(35);} 2931 2932 dbg.location(484,9); 2933 match(input,RBRACE,FOLLOW_RBRACE_in_classBody1489); if (state.failed) return ; 2934 2935 } 2936 2937 } 2938 catch (RecognitionException re) { 2939 reportError(re); 2940 recover(input,re); 2941 } 2942 finally { 2943 if ( state.backtracking>0 ) { memoize(input, 22, classBody_StartIndex); } 2944 } 2945 dbg.location(485, 5); 2946 2947 } 2948 finally { 2949 dbg.exitRule(getGrammarFileName(), "classBody"); 2950 decRuleLevel(); 2951 if ( getRuleLevel()==0 ) {dbg.terminate();} 2952 } 2953 2954 return ; 2955 } 2956 // $ANTLR end "classBody" 2957 2958 2959 // $ANTLR start "interfaceBody" 2960 // src/com/google/doclava/parser/Java.g:487:1: interfaceBody : '{' ( interfaceBodyDeclaration )* '}' ; 2961 public final void interfaceBody() throws RecognitionException { 2962 int interfaceBody_StartIndex = input.index(); 2963 try { dbg.enterRule(getGrammarFileName(), "interfaceBody"); 2964 if ( getRuleLevel()==0 ) {dbg.commence();} 2965 incRuleLevel(); 2966 dbg.location(487, 1); 2967 2968 try { 2969 if ( state.backtracking>0 && alreadyParsedRule(input, 23) ) { return ; } 2970 // src/com/google/doclava/parser/Java.g:488:5: ( '{' ( interfaceBodyDeclaration )* '}' ) 2971 dbg.enterAlt(1); 2972 2973 // src/com/google/doclava/parser/Java.g:488:9: '{' ( interfaceBodyDeclaration )* '}' 2974 { 2975 dbg.location(488,9); 2976 match(input,LBRACE,FOLLOW_LBRACE_in_interfaceBody1508); if (state.failed) return ; 2977 dbg.location(489,9); 2978 // src/com/google/doclava/parser/Java.g:489:9: ( interfaceBodyDeclaration )* 2979 try { dbg.enterSubRule(36); 2980 2981 loop36: 2982 do { 2983 int alt36=2; 2984 try { dbg.enterDecision(36, decisionCanBacktrack[36]); 2985 2986 int LA36_0 = input.LA(1); 2987 2988 if ( (LA36_0==IDENTIFIER||LA36_0==ABSTRACT||LA36_0==BOOLEAN||LA36_0==BYTE||(LA36_0>=CHAR && LA36_0<=CLASS)||LA36_0==DOUBLE||LA36_0==ENUM||LA36_0==FINAL||LA36_0==FLOAT||(LA36_0>=INT && LA36_0<=NATIVE)||(LA36_0>=PRIVATE && LA36_0<=PUBLIC)||(LA36_0>=SHORT && LA36_0<=STRICTFP)||LA36_0==SYNCHRONIZED||LA36_0==TRANSIENT||(LA36_0>=VOID && LA36_0<=VOLATILE)||LA36_0==SEMI||LA36_0==MONKEYS_AT||LA36_0==LT) ) { 2989 alt36=1; 2990 } 2991 2992 2993 } finally {dbg.exitDecision(36);} 2994 2995 switch (alt36) { 2996 case 1 : 2997 dbg.enterAlt(1); 2998 2999 // src/com/google/doclava/parser/Java.g:489:10: interfaceBodyDeclaration 3000 { 3001 dbg.location(489,10); 3002 pushFollow(FOLLOW_interfaceBodyDeclaration_in_interfaceBody1519); 3003 interfaceBodyDeclaration(); 3004 3005 state._fsp--; 3006 if (state.failed) return ; 3007 3008 } 3009 break; 3010 3011 default : 3012 break loop36; 3013 } 3014 } while (true); 3015 } finally {dbg.exitSubRule(36);} 3016 3017 dbg.location(491,9); 3018 match(input,RBRACE,FOLLOW_RBRACE_in_interfaceBody1540); if (state.failed) return ; 3019 3020 } 3021 3022 } 3023 catch (RecognitionException re) { 3024 reportError(re); 3025 recover(input,re); 3026 } 3027 finally { 3028 if ( state.backtracking>0 ) { memoize(input, 23, interfaceBody_StartIndex); } 3029 } 3030 dbg.location(492, 5); 3031 3032 } 3033 finally { 3034 dbg.exitRule(getGrammarFileName(), "interfaceBody"); 3035 decRuleLevel(); 3036 if ( getRuleLevel()==0 ) {dbg.terminate();} 3037 } 3038 3039 return ; 3040 } 3041 // $ANTLR end "interfaceBody" 3042 3043 3044 // $ANTLR start "classBodyDeclaration" 3045 // src/com/google/doclava/parser/Java.g:494:1: classBodyDeclaration : ( ';' | ( 'static' )? block | memberDecl ); 3046 public final void classBodyDeclaration() throws RecognitionException { 3047 int classBodyDeclaration_StartIndex = input.index(); 3048 try { dbg.enterRule(getGrammarFileName(), "classBodyDeclaration"); 3049 if ( getRuleLevel()==0 ) {dbg.commence();} 3050 incRuleLevel(); 3051 dbg.location(494, 1); 3052 3053 try { 3054 if ( state.backtracking>0 && alreadyParsedRule(input, 24) ) { return ; } 3055 // src/com/google/doclava/parser/Java.g:495:5: ( ';' | ( 'static' )? block | memberDecl ) 3056 int alt38=3; 3057 try { dbg.enterDecision(38, decisionCanBacktrack[38]); 3058 3059 switch ( input.LA(1) ) { 3060 case SEMI: 3061 { 3062 alt38=1; 3063 } 3064 break; 3065 case STATIC: 3066 { 3067 int LA38_2 = input.LA(2); 3068 3069 if ( (LA38_2==LBRACE) ) { 3070 alt38=2; 3071 } 3072 else if ( (LA38_2==IDENTIFIER||LA38_2==ABSTRACT||LA38_2==BOOLEAN||LA38_2==BYTE||(LA38_2>=CHAR && LA38_2<=CLASS)||LA38_2==DOUBLE||LA38_2==ENUM||LA38_2==FINAL||LA38_2==FLOAT||(LA38_2>=INT && LA38_2<=NATIVE)||(LA38_2>=PRIVATE && LA38_2<=PUBLIC)||(LA38_2>=SHORT && LA38_2<=STRICTFP)||LA38_2==SYNCHRONIZED||LA38_2==TRANSIENT||(LA38_2>=VOID && LA38_2<=VOLATILE)||LA38_2==MONKEYS_AT||LA38_2==LT) ) { 3073 alt38=3; 3074 } 3075 else { 3076 if (state.backtracking>0) {state.failed=true; return ;} 3077 NoViableAltException nvae = 3078 new NoViableAltException("", 38, 2, input); 3079 3080 dbg.recognitionException(nvae); 3081 throw nvae; 3082 } 3083 } 3084 break; 3085 case LBRACE: 3086 { 3087 alt38=2; 3088 } 3089 break; 3090 case IDENTIFIER: 3091 case ABSTRACT: 3092 case BOOLEAN: 3093 case BYTE: 3094 case CHAR: 3095 case CLASS: 3096 case DOUBLE: 3097 case ENUM: 3098 case FINAL: 3099 case FLOAT: 3100 case INT: 3101 case INTERFACE: 3102 case LONG: 3103 case NATIVE: 3104 case PRIVATE: 3105 case PROTECTED: 3106 case PUBLIC: 3107 case SHORT: 3108 case STRICTFP: 3109 case SYNCHRONIZED: 3110 case TRANSIENT: 3111 case VOID: 3112 case VOLATILE: 3113 case MONKEYS_AT: 3114 case LT: 3115 { 3116 alt38=3; 3117 } 3118 break; 3119 default: 3120 if (state.backtracking>0) {state.failed=true; return ;} 3121 NoViableAltException nvae = 3122 new NoViableAltException("", 38, 0, input); 3123 3124 dbg.recognitionException(nvae); 3125 throw nvae; 3126 } 3127 3128 } finally {dbg.exitDecision(38);} 3129 3130 switch (alt38) { 3131 case 1 : 3132 dbg.enterAlt(1); 3133 3134 // src/com/google/doclava/parser/Java.g:495:9: ';' 3135 { 3136 dbg.location(495,9); 3137 match(input,SEMI,FOLLOW_SEMI_in_classBodyDeclaration1559); if (state.failed) return ; 3138 3139 } 3140 break; 3141 case 2 : 3142 dbg.enterAlt(2); 3143 3144 // src/com/google/doclava/parser/Java.g:496:9: ( 'static' )? block 3145 { 3146 dbg.location(496,9); 3147 // src/com/google/doclava/parser/Java.g:496:9: ( 'static' )? 3148 int alt37=2; 3149 try { dbg.enterSubRule(37); 3150 try { dbg.enterDecision(37, decisionCanBacktrack[37]); 3151 3152 int LA37_0 = input.LA(1); 3153 3154 if ( (LA37_0==STATIC) ) { 3155 alt37=1; 3156 } 3157 } finally {dbg.exitDecision(37);} 3158 3159 switch (alt37) { 3160 case 1 : 3161 dbg.enterAlt(1); 3162 3163 // src/com/google/doclava/parser/Java.g:496:10: 'static' 3164 { 3165 dbg.location(496,10); 3166 match(input,STATIC,FOLLOW_STATIC_in_classBodyDeclaration1570); if (state.failed) return ; 3167 3168 } 3169 break; 3170 3171 } 3172 } finally {dbg.exitSubRule(37);} 3173 3174 dbg.location(498,9); 3175 pushFollow(FOLLOW_block_in_classBodyDeclaration1591); 3176 block(); 3177 3178 state._fsp--; 3179 if (state.failed) return ; 3180 3181 } 3182 break; 3183 case 3 : 3184 dbg.enterAlt(3); 3185 3186 // src/com/google/doclava/parser/Java.g:499:9: memberDecl 3187 { 3188 dbg.location(499,9); 3189 pushFollow(FOLLOW_memberDecl_in_classBodyDeclaration1601); 3190 memberDecl(); 3191 3192 state._fsp--; 3193 if (state.failed) return ; 3194 3195 } 3196 break; 3197 3198 } 3199 } 3200 catch (RecognitionException re) { 3201 reportError(re); 3202 recover(input,re); 3203 } 3204 finally { 3205 if ( state.backtracking>0 ) { memoize(input, 24, classBodyDeclaration_StartIndex); } 3206 } 3207 dbg.location(500, 5); 3208 3209 } 3210 finally { 3211 dbg.exitRule(getGrammarFileName(), "classBodyDeclaration"); 3212 decRuleLevel(); 3213 if ( getRuleLevel()==0 ) {dbg.terminate();} 3214 } 3215 3216 return ; 3217 } 3218 // $ANTLR end "classBodyDeclaration" 3219 3220 3221 // $ANTLR start "memberDecl" 3222 // src/com/google/doclava/parser/Java.g:502:1: memberDecl : ( fieldDeclaration | methodDeclaration | classDeclaration | interfaceDeclaration ); 3223 public final void memberDecl() throws RecognitionException { 3224 int memberDecl_StartIndex = input.index(); 3225 try { dbg.enterRule(getGrammarFileName(), "memberDecl"); 3226 if ( getRuleLevel()==0 ) {dbg.commence();} 3227 incRuleLevel(); 3228 dbg.location(502, 1); 3229 3230 try { 3231 if ( state.backtracking>0 && alreadyParsedRule(input, 25) ) { return ; } 3232 // src/com/google/doclava/parser/Java.g:503:5: ( fieldDeclaration | methodDeclaration | classDeclaration | interfaceDeclaration ) 3233 int alt39=4; 3234 try { dbg.enterDecision(39, decisionCanBacktrack[39]); 3235 3236 try { 3237 isCyclicDecision = true; 3238 alt39 = dfa39.predict(input); 3239 } 3240 catch (NoViableAltException nvae) { 3241 dbg.recognitionException(nvae); 3242 throw nvae; 3243 } 3244 } finally {dbg.exitDecision(39);} 3245 3246 switch (alt39) { 3247 case 1 : 3248 dbg.enterAlt(1); 3249 3250 // src/com/google/doclava/parser/Java.g:503:10: fieldDeclaration 3251 { 3252 dbg.location(503,10); 3253 pushFollow(FOLLOW_fieldDeclaration_in_memberDecl1621); 3254 fieldDeclaration(); 3255 3256 state._fsp--; 3257 if (state.failed) return ; 3258 3259 } 3260 break; 3261 case 2 : 3262 dbg.enterAlt(2); 3263 3264 // src/com/google/doclava/parser/Java.g:504:10: methodDeclaration 3265 { 3266 dbg.location(504,10); 3267 pushFollow(FOLLOW_methodDeclaration_in_memberDecl1632); 3268 methodDeclaration(); 3269 3270 state._fsp--; 3271 if (state.failed) return ; 3272 3273 } 3274 break; 3275 case 3 : 3276 dbg.enterAlt(3); 3277 3278 // src/com/google/doclava/parser/Java.g:505:10: classDeclaration 3279 { 3280 dbg.location(505,10); 3281 pushFollow(FOLLOW_classDeclaration_in_memberDecl1643); 3282 classDeclaration(); 3283 3284 state._fsp--; 3285 if (state.failed) return ; 3286 3287 } 3288 break; 3289 case 4 : 3290 dbg.enterAlt(4); 3291 3292 // src/com/google/doclava/parser/Java.g:506:10: interfaceDeclaration 3293 { 3294 dbg.location(506,10); 3295 pushFollow(FOLLOW_interfaceDeclaration_in_memberDecl1654); 3296 interfaceDeclaration(); 3297 3298 state._fsp--; 3299 if (state.failed) return ; 3300 3301 } 3302 break; 3303 3304 } 3305 } 3306 catch (RecognitionException re) { 3307 reportError(re); 3308 recover(input,re); 3309 } 3310 finally { 3311 if ( state.backtracking>0 ) { memoize(input, 25, memberDecl_StartIndex); } 3312 } 3313 dbg.location(507, 5); 3314 3315 } 3316 finally { 3317 dbg.exitRule(getGrammarFileName(), "memberDecl"); 3318 decRuleLevel(); 3319 if ( getRuleLevel()==0 ) {dbg.terminate();} 3320 } 3321 3322 return ; 3323 } 3324 // $ANTLR end "memberDecl" 3325 3326 3327 // $ANTLR start "methodDeclaration" 3328 // src/com/google/doclava/parser/Java.g:510:1: methodDeclaration : ( modifiers ( typeParameters )? IDENTIFIER formalParameters ( 'throws' qualifiedNameList )? '{' ( explicitConstructorInvocation )? ( blockStatement )* '}' | modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ( block | ';' ) ); 3329 public final void methodDeclaration() throws RecognitionException { 3330 int methodDeclaration_StartIndex = input.index(); 3331 try { dbg.enterRule(getGrammarFileName(), "methodDeclaration"); 3332 if ( getRuleLevel()==0 ) {dbg.commence();} 3333 incRuleLevel(); 3334 dbg.location(510, 1); 3335 3336 try { 3337 if ( state.backtracking>0 && alreadyParsedRule(input, 26) ) { return ; } 3338 // src/com/google/doclava/parser/Java.g:511:5: ( modifiers ( typeParameters )? IDENTIFIER formalParameters ( 'throws' qualifiedNameList )? '{' ( explicitConstructorInvocation )? ( blockStatement )* '}' | modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ( block | ';' ) ) 3339 int alt49=2; 3340 try { dbg.enterDecision(49, decisionCanBacktrack[49]); 3341 3342 try { 3343 isCyclicDecision = true; 3344 alt49 = dfa49.predict(input); 3345 } 3346 catch (NoViableAltException nvae) { 3347 dbg.recognitionException(nvae); 3348 throw nvae; 3349 } 3350 } finally {dbg.exitDecision(49);} 3351 3352 switch (alt49) { 3353 case 1 : 3354 dbg.enterAlt(1); 3355 3356 // src/com/google/doclava/parser/Java.g:513:10: modifiers ( typeParameters )? IDENTIFIER formalParameters ( 'throws' qualifiedNameList )? '{' ( explicitConstructorInvocation )? ( blockStatement )* '}' 3357 { 3358 dbg.location(513,10); 3359 pushFollow(FOLLOW_modifiers_in_methodDeclaration1691); 3360 modifiers(); 3361 3362 state._fsp--; 3363 if (state.failed) return ; 3364 dbg.location(514,9); 3365 // src/com/google/doclava/parser/Java.g:514:9: ( typeParameters )? 3366 int alt40=2; 3367 try { dbg.enterSubRule(40); 3368 try { dbg.enterDecision(40, decisionCanBacktrack[40]); 3369 3370 int LA40_0 = input.LA(1); 3371 3372 if ( (LA40_0==LT) ) { 3373 alt40=1; 3374 } 3375 } finally {dbg.exitDecision(40);} 3376 3377 switch (alt40) { 3378 case 1 : 3379 dbg.enterAlt(1); 3380 3381 // src/com/google/doclava/parser/Java.g:514:10: typeParameters 3382 { 3383 dbg.location(514,10); 3384 pushFollow(FOLLOW_typeParameters_in_methodDeclaration1702); 3385 typeParameters(); 3386 3387 state._fsp--; 3388 if (state.failed) return ; 3389 3390 } 3391 break; 3392 3393 } 3394 } finally {dbg.exitSubRule(40);} 3395 3396 dbg.location(516,9); 3397 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_methodDeclaration1723); if (state.failed) return ; 3398 dbg.location(517,9); 3399 pushFollow(FOLLOW_formalParameters_in_methodDeclaration1733); 3400 formalParameters(); 3401 3402 state._fsp--; 3403 if (state.failed) return ; 3404 dbg.location(518,9); 3405 // src/com/google/doclava/parser/Java.g:518:9: ( 'throws' qualifiedNameList )? 3406 int alt41=2; 3407 try { dbg.enterSubRule(41); 3408 try { dbg.enterDecision(41, decisionCanBacktrack[41]); 3409 3410 int LA41_0 = input.LA(1); 3411 3412 if ( (LA41_0==THROWS) ) { 3413 alt41=1; 3414 } 3415 } finally {dbg.exitDecision(41);} 3416 3417 switch (alt41) { 3418 case 1 : 3419 dbg.enterAlt(1); 3420 3421 // src/com/google/doclava/parser/Java.g:518:10: 'throws' qualifiedNameList 3422 { 3423 dbg.location(518,10); 3424 match(input,THROWS,FOLLOW_THROWS_in_methodDeclaration1744); if (state.failed) return ; 3425 dbg.location(518,19); 3426 pushFollow(FOLLOW_qualifiedNameList_in_methodDeclaration1746); 3427 qualifiedNameList(); 3428 3429 state._fsp--; 3430 if (state.failed) return ; 3431 3432 } 3433 break; 3434 3435 } 3436 } finally {dbg.exitSubRule(41);} 3437 3438 dbg.location(520,9); 3439 match(input,LBRACE,FOLLOW_LBRACE_in_methodDeclaration1767); if (state.failed) return ; 3440 dbg.location(521,9); 3441 // src/com/google/doclava/parser/Java.g:521:9: ( explicitConstructorInvocation )? 3442 int alt42=2; 3443 try { dbg.enterSubRule(42); 3444 try { dbg.enterDecision(42, decisionCanBacktrack[42]); 3445 3446 try { 3447 isCyclicDecision = true; 3448 alt42 = dfa42.predict(input); 3449 } 3450 catch (NoViableAltException nvae) { 3451 dbg.recognitionException(nvae); 3452 throw nvae; 3453 } 3454 } finally {dbg.exitDecision(42);} 3455 3456 switch (alt42) { 3457 case 1 : 3458 dbg.enterAlt(1); 3459 3460 // src/com/google/doclava/parser/Java.g:521:10: explicitConstructorInvocation 3461 { 3462 dbg.location(521,10); 3463 pushFollow(FOLLOW_explicitConstructorInvocation_in_methodDeclaration1778); 3464 explicitConstructorInvocation(); 3465 3466 state._fsp--; 3467 if (state.failed) return ; 3468 3469 } 3470 break; 3471 3472 } 3473 } finally {dbg.exitSubRule(42);} 3474 3475 dbg.location(523,9); 3476 // src/com/google/doclava/parser/Java.g:523:9: ( blockStatement )* 3477 try { dbg.enterSubRule(43); 3478 3479 loop43: 3480 do { 3481 int alt43=2; 3482 try { dbg.enterDecision(43, decisionCanBacktrack[43]); 3483 3484 int LA43_0 = input.LA(1); 3485 3486 if ( ((LA43_0>=IDENTIFIER && LA43_0<=NULL)||(LA43_0>=ABSTRACT && LA43_0<=BYTE)||(LA43_0>=CHAR && LA43_0<=CLASS)||LA43_0==CONTINUE||(LA43_0>=DO && LA43_0<=DOUBLE)||LA43_0==ENUM||LA43_0==FINAL||(LA43_0>=FLOAT && LA43_0<=FOR)||LA43_0==IF||(LA43_0>=INT && LA43_0<=NEW)||(LA43_0>=PRIVATE && LA43_0<=THROW)||(LA43_0>=TRANSIENT && LA43_0<=LPAREN)||LA43_0==LBRACE||LA43_0==SEMI||(LA43_0>=BANG && LA43_0<=TILDE)||(LA43_0>=PLUSPLUS && LA43_0<=SUB)||LA43_0==MONKEYS_AT||LA43_0==LT) ) { 3487 alt43=1; 3488 } 3489 3490 3491 } finally {dbg.exitDecision(43);} 3492 3493 switch (alt43) { 3494 case 1 : 3495 dbg.enterAlt(1); 3496 3497 // src/com/google/doclava/parser/Java.g:523:10: blockStatement 3498 { 3499 dbg.location(523,10); 3500 pushFollow(FOLLOW_blockStatement_in_methodDeclaration1800); 3501 blockStatement(); 3502 3503 state._fsp--; 3504 if (state.failed) return ; 3505 3506 } 3507 break; 3508 3509 default : 3510 break loop43; 3511 } 3512 } while (true); 3513 } finally {dbg.exitSubRule(43);} 3514 3515 dbg.location(525,9); 3516 match(input,RBRACE,FOLLOW_RBRACE_in_methodDeclaration1821); if (state.failed) return ; 3517 3518 } 3519 break; 3520 case 2 : 3521 dbg.enterAlt(2); 3522 3523 // src/com/google/doclava/parser/Java.g:526:9: modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ( block | ';' ) 3524 { 3525 dbg.location(526,9); 3526 pushFollow(FOLLOW_modifiers_in_methodDeclaration1831); 3527 modifiers(); 3528 3529 state._fsp--; 3530 if (state.failed) return ; 3531 dbg.location(527,9); 3532 // src/com/google/doclava/parser/Java.g:527:9: ( typeParameters )? 3533 int alt44=2; 3534 try { dbg.enterSubRule(44); 3535 try { dbg.enterDecision(44, decisionCanBacktrack[44]); 3536 3537 int LA44_0 = input.LA(1); 3538 3539 if ( (LA44_0==LT) ) { 3540 alt44=1; 3541 } 3542 } finally {dbg.exitDecision(44);} 3543 3544 switch (alt44) { 3545 case 1 : 3546 dbg.enterAlt(1); 3547 3548 // src/com/google/doclava/parser/Java.g:527:10: typeParameters 3549 { 3550 dbg.location(527,10); 3551 pushFollow(FOLLOW_typeParameters_in_methodDeclaration1842); 3552 typeParameters(); 3553 3554 state._fsp--; 3555 if (state.failed) return ; 3556 3557 } 3558 break; 3559 3560 } 3561 } finally {dbg.exitSubRule(44);} 3562 3563 dbg.location(529,9); 3564 // src/com/google/doclava/parser/Java.g:529:9: ( type | 'void' ) 3565 int alt45=2; 3566 try { dbg.enterSubRule(45); 3567 try { dbg.enterDecision(45, decisionCanBacktrack[45]); 3568 3569 int LA45_0 = input.LA(1); 3570 3571 if ( (LA45_0==IDENTIFIER||LA45_0==BOOLEAN||LA45_0==BYTE||LA45_0==CHAR||LA45_0==DOUBLE||LA45_0==FLOAT||LA45_0==INT||LA45_0==LONG||LA45_0==SHORT) ) { 3572 alt45=1; 3573 } 3574 else if ( (LA45_0==VOID) ) { 3575 alt45=2; 3576 } 3577 else { 3578 if (state.backtracking>0) {state.failed=true; return ;} 3579 NoViableAltException nvae = 3580 new NoViableAltException("", 45, 0, input); 3581 3582 dbg.recognitionException(nvae); 3583 throw nvae; 3584 } 3585 } finally {dbg.exitDecision(45);} 3586 3587 switch (alt45) { 3588 case 1 : 3589 dbg.enterAlt(1); 3590 3591 // src/com/google/doclava/parser/Java.g:529:10: type 3592 { 3593 dbg.location(529,10); 3594 pushFollow(FOLLOW_type_in_methodDeclaration1864); 3595 type(); 3596 3597 state._fsp--; 3598 if (state.failed) return ; 3599 3600 } 3601 break; 3602 case 2 : 3603 dbg.enterAlt(2); 3604 3605 // src/com/google/doclava/parser/Java.g:530:13: 'void' 3606 { 3607 dbg.location(530,13); 3608 match(input,VOID,FOLLOW_VOID_in_methodDeclaration1878); if (state.failed) return ; 3609 3610 } 3611 break; 3612 3613 } 3614 } finally {dbg.exitSubRule(45);} 3615 3616 dbg.location(532,9); 3617 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_methodDeclaration1898); if (state.failed) return ; 3618 dbg.location(533,9); 3619 pushFollow(FOLLOW_formalParameters_in_methodDeclaration1908); 3620 formalParameters(); 3621 3622 state._fsp--; 3623 if (state.failed) return ; 3624 dbg.location(534,9); 3625 // src/com/google/doclava/parser/Java.g:534:9: ( '[' ']' )* 3626 try { dbg.enterSubRule(46); 3627 3628 loop46: 3629 do { 3630 int alt46=2; 3631 try { dbg.enterDecision(46, decisionCanBacktrack[46]); 3632 3633 int LA46_0 = input.LA(1); 3634 3635 if ( (LA46_0==LBRACKET) ) { 3636 alt46=1; 3637 } 3638 3639 3640 } finally {dbg.exitDecision(46);} 3641 3642 switch (alt46) { 3643 case 1 : 3644 dbg.enterAlt(1); 3645 3646 // src/com/google/doclava/parser/Java.g:534:10: '[' ']' 3647 { 3648 dbg.location(534,10); 3649 match(input,LBRACKET,FOLLOW_LBRACKET_in_methodDeclaration1919); if (state.failed) return ; 3650 dbg.location(534,14); 3651 match(input,RBRACKET,FOLLOW_RBRACKET_in_methodDeclaration1921); if (state.failed) return ; 3652 3653 } 3654 break; 3655 3656 default : 3657 break loop46; 3658 } 3659 } while (true); 3660 } finally {dbg.exitSubRule(46);} 3661 3662 dbg.location(536,9); 3663 // src/com/google/doclava/parser/Java.g:536:9: ( 'throws' qualifiedNameList )? 3664 int alt47=2; 3665 try { dbg.enterSubRule(47); 3666 try { dbg.enterDecision(47, decisionCanBacktrack[47]); 3667 3668 int LA47_0 = input.LA(1); 3669 3670 if ( (LA47_0==THROWS) ) { 3671 alt47=1; 3672 } 3673 } finally {dbg.exitDecision(47);} 3674 3675 switch (alt47) { 3676 case 1 : 3677 dbg.enterAlt(1); 3678 3679 // src/com/google/doclava/parser/Java.g:536:10: 'throws' qualifiedNameList 3680 { 3681 dbg.location(536,10); 3682 match(input,THROWS,FOLLOW_THROWS_in_methodDeclaration1943); if (state.failed) return ; 3683 dbg.location(536,19); 3684 pushFollow(FOLLOW_qualifiedNameList_in_methodDeclaration1945); 3685 qualifiedNameList(); 3686 3687 state._fsp--; 3688 if (state.failed) return ; 3689 3690 } 3691 break; 3692 3693 } 3694 } finally {dbg.exitSubRule(47);} 3695 3696 dbg.location(538,9); 3697 // src/com/google/doclava/parser/Java.g:538:9: ( block | ';' ) 3698 int alt48=2; 3699 try { dbg.enterSubRule(48); 3700 try { dbg.enterDecision(48, decisionCanBacktrack[48]); 3701 3702 int LA48_0 = input.LA(1); 3703 3704 if ( (LA48_0==LBRACE) ) { 3705 alt48=1; 3706 } 3707 else if ( (LA48_0==SEMI) ) { 3708 alt48=2; 3709 } 3710 else { 3711 if (state.backtracking>0) {state.failed=true; return ;} 3712 NoViableAltException nvae = 3713 new NoViableAltException("", 48, 0, input); 3714 3715 dbg.recognitionException(nvae); 3716 throw nvae; 3717 } 3718 } finally {dbg.exitDecision(48);} 3719 3720 switch (alt48) { 3721 case 1 : 3722 dbg.enterAlt(1); 3723 3724 // src/com/google/doclava/parser/Java.g:539:13: block 3725 { 3726 dbg.location(539,13); 3727 pushFollow(FOLLOW_block_in_methodDeclaration1980); 3728 block(); 3729 3730 state._fsp--; 3731 if (state.failed) return ; 3732 3733 } 3734 break; 3735 case 2 : 3736 dbg.enterAlt(2); 3737 3738 // src/com/google/doclava/parser/Java.g:540:13: ';' 3739 { 3740 dbg.location(540,13); 3741 match(input,SEMI,FOLLOW_SEMI_in_methodDeclaration1994); if (state.failed) return ; 3742 3743 } 3744 break; 3745 3746 } 3747 } finally {dbg.exitSubRule(48);} 3748 3749 3750 } 3751 break; 3752 3753 } 3754 } 3755 catch (RecognitionException re) { 3756 reportError(re); 3757 recover(input,re); 3758 } 3759 finally { 3760 if ( state.backtracking>0 ) { memoize(input, 26, methodDeclaration_StartIndex); } 3761 } 3762 dbg.location(542, 5); 3763 3764 } 3765 finally { 3766 dbg.exitRule(getGrammarFileName(), "methodDeclaration"); 3767 decRuleLevel(); 3768 if ( getRuleLevel()==0 ) {dbg.terminate();} 3769 } 3770 3771 return ; 3772 } 3773 // $ANTLR end "methodDeclaration" 3774 3775 3776 // $ANTLR start "fieldDeclaration" 3777 // src/com/google/doclava/parser/Java.g:545:1: fieldDeclaration : modifiers type variableDeclarator ( ',' variableDeclarator )* ';' ; 3778 public final void fieldDeclaration() throws RecognitionException { 3779 int fieldDeclaration_StartIndex = input.index(); 3780 try { dbg.enterRule(getGrammarFileName(), "fieldDeclaration"); 3781 if ( getRuleLevel()==0 ) {dbg.commence();} 3782 incRuleLevel(); 3783 dbg.location(545, 1); 3784 3785 try { 3786 if ( state.backtracking>0 && alreadyParsedRule(input, 27) ) { return ; } 3787 // src/com/google/doclava/parser/Java.g:546:5: ( modifiers type variableDeclarator ( ',' variableDeclarator )* ';' ) 3788 dbg.enterAlt(1); 3789 3790 // src/com/google/doclava/parser/Java.g:546:9: modifiers type variableDeclarator ( ',' variableDeclarator )* ';' 3791 { 3792 dbg.location(546,9); 3793 pushFollow(FOLLOW_modifiers_in_fieldDeclaration2024); 3794 modifiers(); 3795 3796 state._fsp--; 3797 if (state.failed) return ; 3798 dbg.location(547,9); 3799 pushFollow(FOLLOW_type_in_fieldDeclaration2034); 3800 type(); 3801 3802 state._fsp--; 3803 if (state.failed) return ; 3804 dbg.location(548,9); 3805 pushFollow(FOLLOW_variableDeclarator_in_fieldDeclaration2044); 3806 variableDeclarator(); 3807 3808 state._fsp--; 3809 if (state.failed) return ; 3810 dbg.location(549,9); 3811 // src/com/google/doclava/parser/Java.g:549:9: ( ',' variableDeclarator )* 3812 try { dbg.enterSubRule(50); 3813 3814 loop50: 3815 do { 3816 int alt50=2; 3817 try { dbg.enterDecision(50, decisionCanBacktrack[50]); 3818 3819 int LA50_0 = input.LA(1); 3820 3821 if ( (LA50_0==COMMA) ) { 3822 alt50=1; 3823 } 3824 3825 3826 } finally {dbg.exitDecision(50);} 3827 3828 switch (alt50) { 3829 case 1 : 3830 dbg.enterAlt(1); 3831 3832 // src/com/google/doclava/parser/Java.g:549:10: ',' variableDeclarator 3833 { 3834 dbg.location(549,10); 3835 match(input,COMMA,FOLLOW_COMMA_in_fieldDeclaration2055); if (state.failed) return ; 3836 dbg.location(549,14); 3837 pushFollow(FOLLOW_variableDeclarator_in_fieldDeclaration2057); 3838 variableDeclarator(); 3839 3840 state._fsp--; 3841 if (state.failed) return ; 3842 3843 } 3844 break; 3845 3846 default : 3847 break loop50; 3848 } 3849 } while (true); 3850 } finally {dbg.exitSubRule(50);} 3851 3852 dbg.location(551,9); 3853 match(input,SEMI,FOLLOW_SEMI_in_fieldDeclaration2078); if (state.failed) return ; 3854 3855 } 3856 3857 } 3858 catch (RecognitionException re) { 3859 reportError(re); 3860 recover(input,re); 3861 } 3862 finally { 3863 if ( state.backtracking>0 ) { memoize(input, 27, fieldDeclaration_StartIndex); } 3864 } 3865 dbg.location(552, 5); 3866 3867 } 3868 finally { 3869 dbg.exitRule(getGrammarFileName(), "fieldDeclaration"); 3870 decRuleLevel(); 3871 if ( getRuleLevel()==0 ) {dbg.terminate();} 3872 } 3873 3874 return ; 3875 } 3876 // $ANTLR end "fieldDeclaration" 3877 3878 3879 // $ANTLR start "variableDeclarator" 3880 // src/com/google/doclava/parser/Java.g:554:1: variableDeclarator : IDENTIFIER ( '[' ']' )* ( '=' variableInitializer )? ; 3881 public final void variableDeclarator() throws RecognitionException { 3882 int variableDeclarator_StartIndex = input.index(); 3883 try { dbg.enterRule(getGrammarFileName(), "variableDeclarator"); 3884 if ( getRuleLevel()==0 ) {dbg.commence();} 3885 incRuleLevel(); 3886 dbg.location(554, 1); 3887 3888 try { 3889 if ( state.backtracking>0 && alreadyParsedRule(input, 28) ) { return ; } 3890 // src/com/google/doclava/parser/Java.g:555:5: ( IDENTIFIER ( '[' ']' )* ( '=' variableInitializer )? ) 3891 dbg.enterAlt(1); 3892 3893 // src/com/google/doclava/parser/Java.g:555:9: IDENTIFIER ( '[' ']' )* ( '=' variableInitializer )? 3894 { 3895 dbg.location(555,9); 3896 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_variableDeclarator2097); if (state.failed) return ; 3897 dbg.location(556,9); 3898 // src/com/google/doclava/parser/Java.g:556:9: ( '[' ']' )* 3899 try { dbg.enterSubRule(51); 3900 3901 loop51: 3902 do { 3903 int alt51=2; 3904 try { dbg.enterDecision(51, decisionCanBacktrack[51]); 3905 3906 int LA51_0 = input.LA(1); 3907 3908 if ( (LA51_0==LBRACKET) ) { 3909 alt51=1; 3910 } 3911 3912 3913 } finally {dbg.exitDecision(51);} 3914 3915 switch (alt51) { 3916 case 1 : 3917 dbg.enterAlt(1); 3918 3919 // src/com/google/doclava/parser/Java.g:556:10: '[' ']' 3920 { 3921 dbg.location(556,10); 3922 match(input,LBRACKET,FOLLOW_LBRACKET_in_variableDeclarator2108); if (state.failed) return ; 3923 dbg.location(556,14); 3924 match(input,RBRACKET,FOLLOW_RBRACKET_in_variableDeclarator2110); if (state.failed) return ; 3925 3926 } 3927 break; 3928 3929 default : 3930 break loop51; 3931 } 3932 } while (true); 3933 } finally {dbg.exitSubRule(51);} 3934 3935 dbg.location(558,9); 3936 // src/com/google/doclava/parser/Java.g:558:9: ( '=' variableInitializer )? 3937 int alt52=2; 3938 try { dbg.enterSubRule(52); 3939 try { dbg.enterDecision(52, decisionCanBacktrack[52]); 3940 3941 int LA52_0 = input.LA(1); 3942 3943 if ( (LA52_0==EQ) ) { 3944 alt52=1; 3945 } 3946 } finally {dbg.exitDecision(52);} 3947 3948 switch (alt52) { 3949 case 1 : 3950 dbg.enterAlt(1); 3951 3952 // src/com/google/doclava/parser/Java.g:558:10: '=' variableInitializer 3953 { 3954 dbg.location(558,10); 3955 match(input,EQ,FOLLOW_EQ_in_variableDeclarator2132); if (state.failed) return ; 3956 dbg.location(558,14); 3957 pushFollow(FOLLOW_variableInitializer_in_variableDeclarator2134); 3958 variableInitializer(); 3959 3960 state._fsp--; 3961 if (state.failed) return ; 3962 3963 } 3964 break; 3965 3966 } 3967 } finally {dbg.exitSubRule(52);} 3968 3969 3970 } 3971 3972 } 3973 catch (RecognitionException re) { 3974 reportError(re); 3975 recover(input,re); 3976 } 3977 finally { 3978 if ( state.backtracking>0 ) { memoize(input, 28, variableDeclarator_StartIndex); } 3979 } 3980 dbg.location(560, 5); 3981 3982 } 3983 finally { 3984 dbg.exitRule(getGrammarFileName(), "variableDeclarator"); 3985 decRuleLevel(); 3986 if ( getRuleLevel()==0 ) {dbg.terminate();} 3987 } 3988 3989 return ; 3990 } 3991 // $ANTLR end "variableDeclarator" 3992 3993 3994 // $ANTLR start "interfaceBodyDeclaration" 3995 // src/com/google/doclava/parser/Java.g:562:1: interfaceBodyDeclaration : ( interfaceFieldDeclaration | interfaceMethodDeclaration | interfaceDeclaration | classDeclaration | ';' ); 3996 public final void interfaceBodyDeclaration() throws RecognitionException { 3997 int interfaceBodyDeclaration_StartIndex = input.index(); 3998 try { dbg.enterRule(getGrammarFileName(), "interfaceBodyDeclaration"); 3999 if ( getRuleLevel()==0 ) {dbg.commence();} 4000 incRuleLevel(); 4001 dbg.location(562, 1); 4002 4003 try { 4004 if ( state.backtracking>0 && alreadyParsedRule(input, 29) ) { return ; } 4005 // src/com/google/doclava/parser/Java.g:566:5: ( interfaceFieldDeclaration | interfaceMethodDeclaration | interfaceDeclaration | classDeclaration | ';' ) 4006 int alt53=5; 4007 try { dbg.enterDecision(53, decisionCanBacktrack[53]); 4008 4009 try { 4010 isCyclicDecision = true; 4011 alt53 = dfa53.predict(input); 4012 } 4013 catch (NoViableAltException nvae) { 4014 dbg.recognitionException(nvae); 4015 throw nvae; 4016 } 4017 } finally {dbg.exitDecision(53);} 4018 4019 switch (alt53) { 4020 case 1 : 4021 dbg.enterAlt(1); 4022 4023 // src/com/google/doclava/parser/Java.g:567:9: interfaceFieldDeclaration 4024 { 4025 dbg.location(567,9); 4026 pushFollow(FOLLOW_interfaceFieldDeclaration_in_interfaceBodyDeclaration2172); 4027 interfaceFieldDeclaration(); 4028 4029 state._fsp--; 4030 if (state.failed) return ; 4031 4032 } 4033 break; 4034 case 2 : 4035 dbg.enterAlt(2); 4036 4037 // src/com/google/doclava/parser/Java.g:568:9: interfaceMethodDeclaration 4038 { 4039 dbg.location(568,9); 4040 pushFollow(FOLLOW_interfaceMethodDeclaration_in_interfaceBodyDeclaration2182); 4041 interfaceMethodDeclaration(); 4042 4043 state._fsp--; 4044 if (state.failed) return ; 4045 4046 } 4047 break; 4048 case 3 : 4049 dbg.enterAlt(3); 4050 4051 // src/com/google/doclava/parser/Java.g:569:9: interfaceDeclaration 4052 { 4053 dbg.location(569,9); 4054 pushFollow(FOLLOW_interfaceDeclaration_in_interfaceBodyDeclaration2192); 4055 interfaceDeclaration(); 4056 4057 state._fsp--; 4058 if (state.failed) return ; 4059 4060 } 4061 break; 4062 case 4 : 4063 dbg.enterAlt(4); 4064 4065 // src/com/google/doclava/parser/Java.g:570:9: classDeclaration 4066 { 4067 dbg.location(570,9); 4068 pushFollow(FOLLOW_classDeclaration_in_interfaceBodyDeclaration2202); 4069 classDeclaration(); 4070 4071 state._fsp--; 4072 if (state.failed) return ; 4073 4074 } 4075 break; 4076 case 5 : 4077 dbg.enterAlt(5); 4078 4079 // src/com/google/doclava/parser/Java.g:571:9: ';' 4080 { 4081 dbg.location(571,9); 4082 match(input,SEMI,FOLLOW_SEMI_in_interfaceBodyDeclaration2212); if (state.failed) return ; 4083 4084 } 4085 break; 4086 4087 } 4088 } 4089 catch (RecognitionException re) { 4090 reportError(re); 4091 recover(input,re); 4092 } 4093 finally { 4094 if ( state.backtracking>0 ) { memoize(input, 29, interfaceBodyDeclaration_StartIndex); } 4095 } 4096 dbg.location(572, 5); 4097 4098 } 4099 finally { 4100 dbg.exitRule(getGrammarFileName(), "interfaceBodyDeclaration"); 4101 decRuleLevel(); 4102 if ( getRuleLevel()==0 ) {dbg.terminate();} 4103 } 4104 4105 return ; 4106 } 4107 // $ANTLR end "interfaceBodyDeclaration" 4108 4109 4110 // $ANTLR start "interfaceMethodDeclaration" 4111 // src/com/google/doclava/parser/Java.g:574:1: interfaceMethodDeclaration : modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ';' ; 4112 public final void interfaceMethodDeclaration() throws RecognitionException { 4113 int interfaceMethodDeclaration_StartIndex = input.index(); 4114 try { dbg.enterRule(getGrammarFileName(), "interfaceMethodDeclaration"); 4115 if ( getRuleLevel()==0 ) {dbg.commence();} 4116 incRuleLevel(); 4117 dbg.location(574, 1); 4118 4119 try { 4120 if ( state.backtracking>0 && alreadyParsedRule(input, 30) ) { return ; } 4121 // src/com/google/doclava/parser/Java.g:575:5: ( modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ';' ) 4122 dbg.enterAlt(1); 4123 4124 // src/com/google/doclava/parser/Java.g:575:9: modifiers ( typeParameters )? ( type | 'void' ) IDENTIFIER formalParameters ( '[' ']' )* ( 'throws' qualifiedNameList )? ';' 4125 { 4126 dbg.location(575,9); 4127 pushFollow(FOLLOW_modifiers_in_interfaceMethodDeclaration2231); 4128 modifiers(); 4129 4130 state._fsp--; 4131 if (state.failed) return ; 4132 dbg.location(576,9); 4133 // src/com/google/doclava/parser/Java.g:576:9: ( typeParameters )? 4134 int alt54=2; 4135 try { dbg.enterSubRule(54); 4136 try { dbg.enterDecision(54, decisionCanBacktrack[54]); 4137 4138 int LA54_0 = input.LA(1); 4139 4140 if ( (LA54_0==LT) ) { 4141 alt54=1; 4142 } 4143 } finally {dbg.exitDecision(54);} 4144 4145 switch (alt54) { 4146 case 1 : 4147 dbg.enterAlt(1); 4148 4149 // src/com/google/doclava/parser/Java.g:576:10: typeParameters 4150 { 4151 dbg.location(576,10); 4152 pushFollow(FOLLOW_typeParameters_in_interfaceMethodDeclaration2242); 4153 typeParameters(); 4154 4155 state._fsp--; 4156 if (state.failed) return ; 4157 4158 } 4159 break; 4160 4161 } 4162 } finally {dbg.exitSubRule(54);} 4163 4164 dbg.location(578,9); 4165 // src/com/google/doclava/parser/Java.g:578:9: ( type | 'void' ) 4166 int alt55=2; 4167 try { dbg.enterSubRule(55); 4168 try { dbg.enterDecision(55, decisionCanBacktrack[55]); 4169 4170 int LA55_0 = input.LA(1); 4171 4172 if ( (LA55_0==IDENTIFIER||LA55_0==BOOLEAN||LA55_0==BYTE||LA55_0==CHAR||LA55_0==DOUBLE||LA55_0==FLOAT||LA55_0==INT||LA55_0==LONG||LA55_0==SHORT) ) { 4173 alt55=1; 4174 } 4175 else if ( (LA55_0==VOID) ) { 4176 alt55=2; 4177 } 4178 else { 4179 if (state.backtracking>0) {state.failed=true; return ;} 4180 NoViableAltException nvae = 4181 new NoViableAltException("", 55, 0, input); 4182 4183 dbg.recognitionException(nvae); 4184 throw nvae; 4185 } 4186 } finally {dbg.exitDecision(55);} 4187 4188 switch (alt55) { 4189 case 1 : 4190 dbg.enterAlt(1); 4191 4192 // src/com/google/doclava/parser/Java.g:578:10: type 4193 { 4194 dbg.location(578,10); 4195 pushFollow(FOLLOW_type_in_interfaceMethodDeclaration2264); 4196 type(); 4197 4198 state._fsp--; 4199 if (state.failed) return ; 4200 4201 } 4202 break; 4203 case 2 : 4204 dbg.enterAlt(2); 4205 4206 // src/com/google/doclava/parser/Java.g:579:10: 'void' 4207 { 4208 dbg.location(579,10); 4209 match(input,VOID,FOLLOW_VOID_in_interfaceMethodDeclaration2275); if (state.failed) return ; 4210 4211 } 4212 break; 4213 4214 } 4215 } finally {dbg.exitSubRule(55);} 4216 4217 dbg.location(581,9); 4218 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_interfaceMethodDeclaration2295); if (state.failed) return ; 4219 dbg.location(582,9); 4220 pushFollow(FOLLOW_formalParameters_in_interfaceMethodDeclaration2305); 4221 formalParameters(); 4222 4223 state._fsp--; 4224 if (state.failed) return ; 4225 dbg.location(583,9); 4226 // src/com/google/doclava/parser/Java.g:583:9: ( '[' ']' )* 4227 try { dbg.enterSubRule(56); 4228 4229 loop56: 4230 do { 4231 int alt56=2; 4232 try { dbg.enterDecision(56, decisionCanBacktrack[56]); 4233 4234 int LA56_0 = input.LA(1); 4235 4236 if ( (LA56_0==LBRACKET) ) { 4237 alt56=1; 4238 } 4239 4240 4241 } finally {dbg.exitDecision(56);} 4242 4243 switch (alt56) { 4244 case 1 : 4245 dbg.enterAlt(1); 4246 4247 // src/com/google/doclava/parser/Java.g:583:10: '[' ']' 4248 { 4249 dbg.location(583,10); 4250 match(input,LBRACKET,FOLLOW_LBRACKET_in_interfaceMethodDeclaration2316); if (state.failed) return ; 4251 dbg.location(583,14); 4252 match(input,RBRACKET,FOLLOW_RBRACKET_in_interfaceMethodDeclaration2318); if (state.failed) return ; 4253 4254 } 4255 break; 4256 4257 default : 4258 break loop56; 4259 } 4260 } while (true); 4261 } finally {dbg.exitSubRule(56);} 4262 4263 dbg.location(585,9); 4264 // src/com/google/doclava/parser/Java.g:585:9: ( 'throws' qualifiedNameList )? 4265 int alt57=2; 4266 try { dbg.enterSubRule(57); 4267 try { dbg.enterDecision(57, decisionCanBacktrack[57]); 4268 4269 int LA57_0 = input.LA(1); 4270 4271 if ( (LA57_0==THROWS) ) { 4272 alt57=1; 4273 } 4274 } finally {dbg.exitDecision(57);} 4275 4276 switch (alt57) { 4277 case 1 : 4278 dbg.enterAlt(1); 4279 4280 // src/com/google/doclava/parser/Java.g:585:10: 'throws' qualifiedNameList 4281 { 4282 dbg.location(585,10); 4283 match(input,THROWS,FOLLOW_THROWS_in_interfaceMethodDeclaration2340); if (state.failed) return ; 4284 dbg.location(585,19); 4285 pushFollow(FOLLOW_qualifiedNameList_in_interfaceMethodDeclaration2342); 4286 qualifiedNameList(); 4287 4288 state._fsp--; 4289 if (state.failed) return ; 4290 4291 } 4292 break; 4293 4294 } 4295 } finally {dbg.exitSubRule(57);} 4296 4297 dbg.location(586,12); 4298 match(input,SEMI,FOLLOW_SEMI_in_interfaceMethodDeclaration2355); if (state.failed) return ; 4299 4300 } 4301 4302 } 4303 catch (RecognitionException re) { 4304 reportError(re); 4305 recover(input,re); 4306 } 4307 finally { 4308 if ( state.backtracking>0 ) { memoize(input, 30, interfaceMethodDeclaration_StartIndex); } 4309 } 4310 dbg.location(587, 5); 4311 4312 } 4313 finally { 4314 dbg.exitRule(getGrammarFileName(), "interfaceMethodDeclaration"); 4315 decRuleLevel(); 4316 if ( getRuleLevel()==0 ) {dbg.terminate();} 4317 } 4318 4319 return ; 4320 } 4321 // $ANTLR end "interfaceMethodDeclaration" 4322 4323 4324 // $ANTLR start "interfaceFieldDeclaration" 4325 // src/com/google/doclava/parser/Java.g:589:1: interfaceFieldDeclaration : modifiers type variableDeclarator ( ',' variableDeclarator )* ';' ; 4326 public final void interfaceFieldDeclaration() throws RecognitionException { 4327 int interfaceFieldDeclaration_StartIndex = input.index(); 4328 try { dbg.enterRule(getGrammarFileName(), "interfaceFieldDeclaration"); 4329 if ( getRuleLevel()==0 ) {dbg.commence();} 4330 incRuleLevel(); 4331 dbg.location(589, 1); 4332 4333 try { 4334 if ( state.backtracking>0 && alreadyParsedRule(input, 31) ) { return ; } 4335 // src/com/google/doclava/parser/Java.g:595:5: ( modifiers type variableDeclarator ( ',' variableDeclarator )* ';' ) 4336 dbg.enterAlt(1); 4337 4338 // src/com/google/doclava/parser/Java.g:595:9: modifiers type variableDeclarator ( ',' variableDeclarator )* ';' 4339 { 4340 dbg.location(595,9); 4341 pushFollow(FOLLOW_modifiers_in_interfaceFieldDeclaration2376); 4342 modifiers(); 4343 4344 state._fsp--; 4345 if (state.failed) return ; 4346 dbg.location(595,19); 4347 pushFollow(FOLLOW_type_in_interfaceFieldDeclaration2378); 4348 type(); 4349 4350 state._fsp--; 4351 if (state.failed) return ; 4352 dbg.location(595,24); 4353 pushFollow(FOLLOW_variableDeclarator_in_interfaceFieldDeclaration2380); 4354 variableDeclarator(); 4355 4356 state._fsp--; 4357 if (state.failed) return ; 4358 dbg.location(596,9); 4359 // src/com/google/doclava/parser/Java.g:596:9: ( ',' variableDeclarator )* 4360 try { dbg.enterSubRule(58); 4361 4362 loop58: 4363 do { 4364 int alt58=2; 4365 try { dbg.enterDecision(58, decisionCanBacktrack[58]); 4366 4367 int LA58_0 = input.LA(1); 4368 4369 if ( (LA58_0==COMMA) ) { 4370 alt58=1; 4371 } 4372 4373 4374 } finally {dbg.exitDecision(58);} 4375 4376 switch (alt58) { 4377 case 1 : 4378 dbg.enterAlt(1); 4379 4380 // src/com/google/doclava/parser/Java.g:596:10: ',' variableDeclarator 4381 { 4382 dbg.location(596,10); 4383 match(input,COMMA,FOLLOW_COMMA_in_interfaceFieldDeclaration2391); if (state.failed) return ; 4384 dbg.location(596,14); 4385 pushFollow(FOLLOW_variableDeclarator_in_interfaceFieldDeclaration2393); 4386 variableDeclarator(); 4387 4388 state._fsp--; 4389 if (state.failed) return ; 4390 4391 } 4392 break; 4393 4394 default : 4395 break loop58; 4396 } 4397 } while (true); 4398 } finally {dbg.exitSubRule(58);} 4399 4400 dbg.location(598,9); 4401 match(input,SEMI,FOLLOW_SEMI_in_interfaceFieldDeclaration2414); if (state.failed) return ; 4402 4403 } 4404 4405 } 4406 catch (RecognitionException re) { 4407 reportError(re); 4408 recover(input,re); 4409 } 4410 finally { 4411 if ( state.backtracking>0 ) { memoize(input, 31, interfaceFieldDeclaration_StartIndex); } 4412 } 4413 dbg.location(599, 5); 4414 4415 } 4416 finally { 4417 dbg.exitRule(getGrammarFileName(), "interfaceFieldDeclaration"); 4418 decRuleLevel(); 4419 if ( getRuleLevel()==0 ) {dbg.terminate();} 4420 } 4421 4422 return ; 4423 } 4424 // $ANTLR end "interfaceFieldDeclaration" 4425 4426 4427 // $ANTLR start "type" 4428 // src/com/google/doclava/parser/Java.g:602:1: type : ( classOrInterfaceType ( '[' ']' )* | primitiveType ( '[' ']' )* ); 4429 public final void type() throws RecognitionException { 4430 int type_StartIndex = input.index(); 4431 try { dbg.enterRule(getGrammarFileName(), "type"); 4432 if ( getRuleLevel()==0 ) {dbg.commence();} 4433 incRuleLevel(); 4434 dbg.location(602, 1); 4435 4436 try { 4437 if ( state.backtracking>0 && alreadyParsedRule(input, 32) ) { return ; } 4438 // src/com/google/doclava/parser/Java.g:603:5: ( classOrInterfaceType ( '[' ']' )* | primitiveType ( '[' ']' )* ) 4439 int alt61=2; 4440 try { dbg.enterDecision(61, decisionCanBacktrack[61]); 4441 4442 int LA61_0 = input.LA(1); 4443 4444 if ( (LA61_0==IDENTIFIER) ) { 4445 alt61=1; 4446 } 4447 else if ( (LA61_0==BOOLEAN||LA61_0==BYTE||LA61_0==CHAR||LA61_0==DOUBLE||LA61_0==FLOAT||LA61_0==INT||LA61_0==LONG||LA61_0==SHORT) ) { 4448 alt61=2; 4449 } 4450 else { 4451 if (state.backtracking>0) {state.failed=true; return ;} 4452 NoViableAltException nvae = 4453 new NoViableAltException("", 61, 0, input); 4454 4455 dbg.recognitionException(nvae); 4456 throw nvae; 4457 } 4458 } finally {dbg.exitDecision(61);} 4459 4460 switch (alt61) { 4461 case 1 : 4462 dbg.enterAlt(1); 4463 4464 // src/com/google/doclava/parser/Java.g:603:9: classOrInterfaceType ( '[' ']' )* 4465 { 4466 dbg.location(603,9); 4467 pushFollow(FOLLOW_classOrInterfaceType_in_type2434); 4468 classOrInterfaceType(); 4469 4470 state._fsp--; 4471 if (state.failed) return ; 4472 dbg.location(604,9); 4473 // src/com/google/doclava/parser/Java.g:604:9: ( '[' ']' )* 4474 try { dbg.enterSubRule(59); 4475 4476 loop59: 4477 do { 4478 int alt59=2; 4479 try { dbg.enterDecision(59, decisionCanBacktrack[59]); 4480 4481 int LA59_0 = input.LA(1); 4482 4483 if ( (LA59_0==LBRACKET) ) { 4484 alt59=1; 4485 } 4486 4487 4488 } finally {dbg.exitDecision(59);} 4489 4490 switch (alt59) { 4491 case 1 : 4492 dbg.enterAlt(1); 4493 4494 // src/com/google/doclava/parser/Java.g:604:10: '[' ']' 4495 { 4496 dbg.location(604,10); 4497 match(input,LBRACKET,FOLLOW_LBRACKET_in_type2445); if (state.failed) return ; 4498 dbg.location(604,14); 4499 match(input,RBRACKET,FOLLOW_RBRACKET_in_type2447); if (state.failed) return ; 4500 4501 } 4502 break; 4503 4504 default : 4505 break loop59; 4506 } 4507 } while (true); 4508 } finally {dbg.exitSubRule(59);} 4509 4510 4511 } 4512 break; 4513 case 2 : 4514 dbg.enterAlt(2); 4515 4516 // src/com/google/doclava/parser/Java.g:606:9: primitiveType ( '[' ']' )* 4517 { 4518 dbg.location(606,9); 4519 pushFollow(FOLLOW_primitiveType_in_type2468); 4520 primitiveType(); 4521 4522 state._fsp--; 4523 if (state.failed) return ; 4524 dbg.location(607,9); 4525 // src/com/google/doclava/parser/Java.g:607:9: ( '[' ']' )* 4526 try { dbg.enterSubRule(60); 4527 4528 loop60: 4529 do { 4530 int alt60=2; 4531 try { dbg.enterDecision(60, decisionCanBacktrack[60]); 4532 4533 int LA60_0 = input.LA(1); 4534 4535 if ( (LA60_0==LBRACKET) ) { 4536 alt60=1; 4537 } 4538 4539 4540 } finally {dbg.exitDecision(60);} 4541 4542 switch (alt60) { 4543 case 1 : 4544 dbg.enterAlt(1); 4545 4546 // src/com/google/doclava/parser/Java.g:607:10: '[' ']' 4547 { 4548 dbg.location(607,10); 4549 match(input,LBRACKET,FOLLOW_LBRACKET_in_type2479); if (state.failed) return ; 4550 dbg.location(607,14); 4551 match(input,RBRACKET,FOLLOW_RBRACKET_in_type2481); if (state.failed) return ; 4552 4553 } 4554 break; 4555 4556 default : 4557 break loop60; 4558 } 4559 } while (true); 4560 } finally {dbg.exitSubRule(60);} 4561 4562 4563 } 4564 break; 4565 4566 } 4567 } 4568 catch (RecognitionException re) { 4569 reportError(re); 4570 recover(input,re); 4571 } 4572 finally { 4573 if ( state.backtracking>0 ) { memoize(input, 32, type_StartIndex); } 4574 } 4575 dbg.location(609, 5); 4576 4577 } 4578 finally { 4579 dbg.exitRule(getGrammarFileName(), "type"); 4580 decRuleLevel(); 4581 if ( getRuleLevel()==0 ) {dbg.terminate();} 4582 } 4583 4584 return ; 4585 } 4586 // $ANTLR end "type" 4587 4588 4589 // $ANTLR start "classOrInterfaceType" 4590 // src/com/google/doclava/parser/Java.g:612:1: classOrInterfaceType : IDENTIFIER ( typeArguments )? ( '.' IDENTIFIER ( typeArguments )? )* ; 4591 public final void classOrInterfaceType() throws RecognitionException { 4592 int classOrInterfaceType_StartIndex = input.index(); 4593 try { dbg.enterRule(getGrammarFileName(), "classOrInterfaceType"); 4594 if ( getRuleLevel()==0 ) {dbg.commence();} 4595 incRuleLevel(); 4596 dbg.location(612, 1); 4597 4598 try { 4599 if ( state.backtracking>0 && alreadyParsedRule(input, 33) ) { return ; } 4600 // src/com/google/doclava/parser/Java.g:613:5: ( IDENTIFIER ( typeArguments )? ( '.' IDENTIFIER ( typeArguments )? )* ) 4601 dbg.enterAlt(1); 4602 4603 // src/com/google/doclava/parser/Java.g:613:9: IDENTIFIER ( typeArguments )? ( '.' IDENTIFIER ( typeArguments )? )* 4604 { 4605 dbg.location(613,9); 4606 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_classOrInterfaceType2512); if (state.failed) return ; 4607 dbg.location(614,9); 4608 // src/com/google/doclava/parser/Java.g:614:9: ( typeArguments )? 4609 int alt62=2; 4610 try { dbg.enterSubRule(62); 4611 try { dbg.enterDecision(62, decisionCanBacktrack[62]); 4612 4613 int LA62_0 = input.LA(1); 4614 4615 if ( (LA62_0==LT) ) { 4616 int LA62_1 = input.LA(2); 4617 4618 if ( (LA62_1==IDENTIFIER||LA62_1==BOOLEAN||LA62_1==BYTE||LA62_1==CHAR||LA62_1==DOUBLE||LA62_1==FLOAT||LA62_1==INT||LA62_1==LONG||LA62_1==SHORT||LA62_1==QUES) ) { 4619 alt62=1; 4620 } 4621 } 4622 } finally {dbg.exitDecision(62);} 4623 4624 switch (alt62) { 4625 case 1 : 4626 dbg.enterAlt(1); 4627 4628 // src/com/google/doclava/parser/Java.g:614:10: typeArguments 4629 { 4630 dbg.location(614,10); 4631 pushFollow(FOLLOW_typeArguments_in_classOrInterfaceType2523); 4632 typeArguments(); 4633 4634 state._fsp--; 4635 if (state.failed) return ; 4636 4637 } 4638 break; 4639 4640 } 4641 } finally {dbg.exitSubRule(62);} 4642 4643 dbg.location(616,9); 4644 // src/com/google/doclava/parser/Java.g:616:9: ( '.' IDENTIFIER ( typeArguments )? )* 4645 try { dbg.enterSubRule(64); 4646 4647 loop64: 4648 do { 4649 int alt64=2; 4650 try { dbg.enterDecision(64, decisionCanBacktrack[64]); 4651 4652 int LA64_0 = input.LA(1); 4653 4654 if ( (LA64_0==DOT) ) { 4655 alt64=1; 4656 } 4657 4658 4659 } finally {dbg.exitDecision(64);} 4660 4661 switch (alt64) { 4662 case 1 : 4663 dbg.enterAlt(1); 4664 4665 // src/com/google/doclava/parser/Java.g:616:10: '.' IDENTIFIER ( typeArguments )? 4666 { 4667 dbg.location(616,10); 4668 match(input,DOT,FOLLOW_DOT_in_classOrInterfaceType2545); if (state.failed) return ; 4669 dbg.location(616,14); 4670 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_classOrInterfaceType2547); if (state.failed) return ; 4671 dbg.location(617,13); 4672 // src/com/google/doclava/parser/Java.g:617:13: ( typeArguments )? 4673 int alt63=2; 4674 try { dbg.enterSubRule(63); 4675 try { dbg.enterDecision(63, decisionCanBacktrack[63]); 4676 4677 int LA63_0 = input.LA(1); 4678 4679 if ( (LA63_0==LT) ) { 4680 int LA63_1 = input.LA(2); 4681 4682 if ( (LA63_1==IDENTIFIER||LA63_1==BOOLEAN||LA63_1==BYTE||LA63_1==CHAR||LA63_1==DOUBLE||LA63_1==FLOAT||LA63_1==INT||LA63_1==LONG||LA63_1==SHORT||LA63_1==QUES) ) { 4683 alt63=1; 4684 } 4685 } 4686 } finally {dbg.exitDecision(63);} 4687 4688 switch (alt63) { 4689 case 1 : 4690 dbg.enterAlt(1); 4691 4692 // src/com/google/doclava/parser/Java.g:617:14: typeArguments 4693 { 4694 dbg.location(617,14); 4695 pushFollow(FOLLOW_typeArguments_in_classOrInterfaceType2562); 4696 typeArguments(); 4697 4698 state._fsp--; 4699 if (state.failed) return ; 4700 4701 } 4702 break; 4703 4704 } 4705 } finally {dbg.exitSubRule(63);} 4706 4707 4708 } 4709 break; 4710 4711 default : 4712 break loop64; 4713 } 4714 } while (true); 4715 } finally {dbg.exitSubRule(64);} 4716 4717 4718 } 4719 4720 } 4721 catch (RecognitionException re) { 4722 reportError(re); 4723 recover(input,re); 4724 } 4725 finally { 4726 if ( state.backtracking>0 ) { memoize(input, 33, classOrInterfaceType_StartIndex); } 4727 } 4728 dbg.location(620, 5); 4729 4730 } 4731 finally { 4732 dbg.exitRule(getGrammarFileName(), "classOrInterfaceType"); 4733 decRuleLevel(); 4734 if ( getRuleLevel()==0 ) {dbg.terminate();} 4735 } 4736 4737 return ; 4738 } 4739 // $ANTLR end "classOrInterfaceType" 4740 4741 4742 // $ANTLR start "primitiveType" 4743 // src/com/google/doclava/parser/Java.g:622:1: primitiveType : ( 'boolean' | 'char' | 'byte' | 'short' | 'int' | 'long' | 'float' | 'double' ); 4744 public final void primitiveType() throws RecognitionException { 4745 int primitiveType_StartIndex = input.index(); 4746 try { dbg.enterRule(getGrammarFileName(), "primitiveType"); 4747 if ( getRuleLevel()==0 ) {dbg.commence();} 4748 incRuleLevel(); 4749 dbg.location(622, 1); 4750 4751 try { 4752 if ( state.backtracking>0 && alreadyParsedRule(input, 34) ) { return ; } 4753 // src/com/google/doclava/parser/Java.g:623:5: ( 'boolean' | 'char' | 'byte' | 'short' | 'int' | 'long' | 'float' | 'double' ) 4754 dbg.enterAlt(1); 4755 4756 // src/com/google/doclava/parser/Java.g: 4757 { 4758 dbg.location(623,5); 4759 if ( input.LA(1)==BOOLEAN||input.LA(1)==BYTE||input.LA(1)==CHAR||input.LA(1)==DOUBLE||input.LA(1)==FLOAT||input.LA(1)==INT||input.LA(1)==LONG||input.LA(1)==SHORT ) { 4760 input.consume(); 4761 state.errorRecovery=false;state.failed=false; 4762 } 4763 else { 4764 if (state.backtracking>0) {state.failed=true; return ;} 4765 MismatchedSetException mse = new MismatchedSetException(null,input); 4766 dbg.recognitionException(mse); 4767 throw mse; 4768 } 4769 4770 4771 } 4772 4773 } 4774 catch (RecognitionException re) { 4775 reportError(re); 4776 recover(input,re); 4777 } 4778 finally { 4779 if ( state.backtracking>0 ) { memoize(input, 34, primitiveType_StartIndex); } 4780 } 4781 dbg.location(631, 5); 4782 4783 } 4784 finally { 4785 dbg.exitRule(getGrammarFileName(), "primitiveType"); 4786 decRuleLevel(); 4787 if ( getRuleLevel()==0 ) {dbg.terminate();} 4788 } 4789 4790 return ; 4791 } 4792 // $ANTLR end "primitiveType" 4793 4794 4795 // $ANTLR start "typeArguments" 4796 // src/com/google/doclava/parser/Java.g:633:1: typeArguments : '<' typeArgument ( ',' typeArgument )* '>' ; 4797 public final void typeArguments() throws RecognitionException { 4798 int typeArguments_StartIndex = input.index(); 4799 try { dbg.enterRule(getGrammarFileName(), "typeArguments"); 4800 if ( getRuleLevel()==0 ) {dbg.commence();} 4801 incRuleLevel(); 4802 dbg.location(633, 1); 4803 4804 try { 4805 if ( state.backtracking>0 && alreadyParsedRule(input, 35) ) { return ; } 4806 // src/com/google/doclava/parser/Java.g:634:5: ( '<' typeArgument ( ',' typeArgument )* '>' ) 4807 dbg.enterAlt(1); 4808 4809 // src/com/google/doclava/parser/Java.g:634:9: '<' typeArgument ( ',' typeArgument )* '>' 4810 { 4811 dbg.location(634,9); 4812 match(input,LT,FOLLOW_LT_in_typeArguments2696); if (state.failed) return ; 4813 dbg.location(634,13); 4814 pushFollow(FOLLOW_typeArgument_in_typeArguments2698); 4815 typeArgument(); 4816 4817 state._fsp--; 4818 if (state.failed) return ; 4819 dbg.location(635,9); 4820 // src/com/google/doclava/parser/Java.g:635:9: ( ',' typeArgument )* 4821 try { dbg.enterSubRule(65); 4822 4823 loop65: 4824 do { 4825 int alt65=2; 4826 try { dbg.enterDecision(65, decisionCanBacktrack[65]); 4827 4828 int LA65_0 = input.LA(1); 4829 4830 if ( (LA65_0==COMMA) ) { 4831 alt65=1; 4832 } 4833 4834 4835 } finally {dbg.exitDecision(65);} 4836 4837 switch (alt65) { 4838 case 1 : 4839 dbg.enterAlt(1); 4840 4841 // src/com/google/doclava/parser/Java.g:635:10: ',' typeArgument 4842 { 4843 dbg.location(635,10); 4844 match(input,COMMA,FOLLOW_COMMA_in_typeArguments2709); if (state.failed) return ; 4845 dbg.location(635,14); 4846 pushFollow(FOLLOW_typeArgument_in_typeArguments2711); 4847 typeArgument(); 4848 4849 state._fsp--; 4850 if (state.failed) return ; 4851 4852 } 4853 break; 4854 4855 default : 4856 break loop65; 4857 } 4858 } while (true); 4859 } finally {dbg.exitSubRule(65);} 4860 4861 dbg.location(637,9); 4862 match(input,GT,FOLLOW_GT_in_typeArguments2732); if (state.failed) return ; 4863 4864 } 4865 4866 } 4867 catch (RecognitionException re) { 4868 reportError(re); 4869 recover(input,re); 4870 } 4871 finally { 4872 if ( state.backtracking>0 ) { memoize(input, 35, typeArguments_StartIndex); } 4873 } 4874 dbg.location(638, 5); 4875 4876 } 4877 finally { 4878 dbg.exitRule(getGrammarFileName(), "typeArguments"); 4879 decRuleLevel(); 4880 if ( getRuleLevel()==0 ) {dbg.terminate();} 4881 } 4882 4883 return ; 4884 } 4885 // $ANTLR end "typeArguments" 4886 4887 4888 // $ANTLR start "typeArgument" 4889 // src/com/google/doclava/parser/Java.g:640:1: typeArgument : ( type | '?' ( ( 'extends' | 'super' ) type )? ); 4890 public final void typeArgument() throws RecognitionException { 4891 int typeArgument_StartIndex = input.index(); 4892 try { dbg.enterRule(getGrammarFileName(), "typeArgument"); 4893 if ( getRuleLevel()==0 ) {dbg.commence();} 4894 incRuleLevel(); 4895 dbg.location(640, 1); 4896 4897 try { 4898 if ( state.backtracking>0 && alreadyParsedRule(input, 36) ) { return ; } 4899 // src/com/google/doclava/parser/Java.g:641:5: ( type | '?' ( ( 'extends' | 'super' ) type )? ) 4900 int alt67=2; 4901 try { dbg.enterDecision(67, decisionCanBacktrack[67]); 4902 4903 int LA67_0 = input.LA(1); 4904 4905 if ( (LA67_0==IDENTIFIER||LA67_0==BOOLEAN||LA67_0==BYTE||LA67_0==CHAR||LA67_0==DOUBLE||LA67_0==FLOAT||LA67_0==INT||LA67_0==LONG||LA67_0==SHORT) ) { 4906 alt67=1; 4907 } 4908 else if ( (LA67_0==QUES) ) { 4909 alt67=2; 4910 } 4911 else { 4912 if (state.backtracking>0) {state.failed=true; return ;} 4913 NoViableAltException nvae = 4914 new NoViableAltException("", 67, 0, input); 4915 4916 dbg.recognitionException(nvae); 4917 throw nvae; 4918 } 4919 } finally {dbg.exitDecision(67);} 4920 4921 switch (alt67) { 4922 case 1 : 4923 dbg.enterAlt(1); 4924 4925 // src/com/google/doclava/parser/Java.g:641:9: type 4926 { 4927 dbg.location(641,9); 4928 pushFollow(FOLLOW_type_in_typeArgument2751); 4929 type(); 4930 4931 state._fsp--; 4932 if (state.failed) return ; 4933 4934 } 4935 break; 4936 case 2 : 4937 dbg.enterAlt(2); 4938 4939 // src/com/google/doclava/parser/Java.g:642:9: '?' ( ( 'extends' | 'super' ) type )? 4940 { 4941 dbg.location(642,9); 4942 match(input,QUES,FOLLOW_QUES_in_typeArgument2761); if (state.failed) return ; 4943 dbg.location(643,9); 4944 // src/com/google/doclava/parser/Java.g:643:9: ( ( 'extends' | 'super' ) type )? 4945 int alt66=2; 4946 try { dbg.enterSubRule(66); 4947 try { dbg.enterDecision(66, decisionCanBacktrack[66]); 4948 4949 int LA66_0 = input.LA(1); 4950 4951 if ( (LA66_0==EXTENDS||LA66_0==SUPER) ) { 4952 alt66=1; 4953 } 4954 } finally {dbg.exitDecision(66);} 4955 4956 switch (alt66) { 4957 case 1 : 4958 dbg.enterAlt(1); 4959 4960 // src/com/google/doclava/parser/Java.g:644:13: ( 'extends' | 'super' ) type 4961 { 4962 dbg.location(644,13); 4963 if ( input.LA(1)==EXTENDS||input.LA(1)==SUPER ) { 4964 input.consume(); 4965 state.errorRecovery=false;state.failed=false; 4966 } 4967 else { 4968 if (state.backtracking>0) {state.failed=true; return ;} 4969 MismatchedSetException mse = new MismatchedSetException(null,input); 4970 dbg.recognitionException(mse); 4971 throw mse; 4972 } 4973 4974 dbg.location(647,13); 4975 pushFollow(FOLLOW_type_in_typeArgument2829); 4976 type(); 4977 4978 state._fsp--; 4979 if (state.failed) return ; 4980 4981 } 4982 break; 4983 4984 } 4985 } finally {dbg.exitSubRule(66);} 4986 4987 4988 } 4989 break; 4990 4991 } 4992 } 4993 catch (RecognitionException re) { 4994 reportError(re); 4995 recover(input,re); 4996 } 4997 finally { 4998 if ( state.backtracking>0 ) { memoize(input, 36, typeArgument_StartIndex); } 4999 } 5000 dbg.location(649, 5); 5001 5002 } 5003 finally { 5004 dbg.exitRule(getGrammarFileName(), "typeArgument"); 5005 decRuleLevel(); 5006 if ( getRuleLevel()==0 ) {dbg.terminate();} 5007 } 5008 5009 return ; 5010 } 5011 // $ANTLR end "typeArgument" 5012 5013 5014 // $ANTLR start "qualifiedNameList" 5015 // src/com/google/doclava/parser/Java.g:651:1: qualifiedNameList : qualifiedName ( ',' qualifiedName )* ; 5016 public final void qualifiedNameList() throws RecognitionException { 5017 int qualifiedNameList_StartIndex = input.index(); 5018 try { dbg.enterRule(getGrammarFileName(), "qualifiedNameList"); 5019 if ( getRuleLevel()==0 ) {dbg.commence();} 5020 incRuleLevel(); 5021 dbg.location(651, 1); 5022 5023 try { 5024 if ( state.backtracking>0 && alreadyParsedRule(input, 37) ) { return ; } 5025 // src/com/google/doclava/parser/Java.g:652:5: ( qualifiedName ( ',' qualifiedName )* ) 5026 dbg.enterAlt(1); 5027 5028 // src/com/google/doclava/parser/Java.g:652:9: qualifiedName ( ',' qualifiedName )* 5029 { 5030 dbg.location(652,9); 5031 pushFollow(FOLLOW_qualifiedName_in_qualifiedNameList2859); 5032 qualifiedName(); 5033 5034 state._fsp--; 5035 if (state.failed) return ; 5036 dbg.location(653,9); 5037 // src/com/google/doclava/parser/Java.g:653:9: ( ',' qualifiedName )* 5038 try { dbg.enterSubRule(68); 5039 5040 loop68: 5041 do { 5042 int alt68=2; 5043 try { dbg.enterDecision(68, decisionCanBacktrack[68]); 5044 5045 int LA68_0 = input.LA(1); 5046 5047 if ( (LA68_0==COMMA) ) { 5048 alt68=1; 5049 } 5050 5051 5052 } finally {dbg.exitDecision(68);} 5053 5054 switch (alt68) { 5055 case 1 : 5056 dbg.enterAlt(1); 5057 5058 // src/com/google/doclava/parser/Java.g:653:10: ',' qualifiedName 5059 { 5060 dbg.location(653,10); 5061 match(input,COMMA,FOLLOW_COMMA_in_qualifiedNameList2870); if (state.failed) return ; 5062 dbg.location(653,14); 5063 pushFollow(FOLLOW_qualifiedName_in_qualifiedNameList2872); 5064 qualifiedName(); 5065 5066 state._fsp--; 5067 if (state.failed) return ; 5068 5069 } 5070 break; 5071 5072 default : 5073 break loop68; 5074 } 5075 } while (true); 5076 } finally {dbg.exitSubRule(68);} 5077 5078 5079 } 5080 5081 } 5082 catch (RecognitionException re) { 5083 reportError(re); 5084 recover(input,re); 5085 } 5086 finally { 5087 if ( state.backtracking>0 ) { memoize(input, 37, qualifiedNameList_StartIndex); } 5088 } 5089 dbg.location(655, 5); 5090 5091 } 5092 finally { 5093 dbg.exitRule(getGrammarFileName(), "qualifiedNameList"); 5094 decRuleLevel(); 5095 if ( getRuleLevel()==0 ) {dbg.terminate();} 5096 } 5097 5098 return ; 5099 } 5100 // $ANTLR end "qualifiedNameList" 5101 5102 5103 // $ANTLR start "formalParameters" 5104 // src/com/google/doclava/parser/Java.g:657:1: formalParameters : '(' ( formalParameterDecls )? ')' ; 5105 public final void formalParameters() throws RecognitionException { 5106 int formalParameters_StartIndex = input.index(); 5107 try { dbg.enterRule(getGrammarFileName(), "formalParameters"); 5108 if ( getRuleLevel()==0 ) {dbg.commence();} 5109 incRuleLevel(); 5110 dbg.location(657, 1); 5111 5112 try { 5113 if ( state.backtracking>0 && alreadyParsedRule(input, 38) ) { return ; } 5114 // src/com/google/doclava/parser/Java.g:658:5: ( '(' ( formalParameterDecls )? ')' ) 5115 dbg.enterAlt(1); 5116 5117 // src/com/google/doclava/parser/Java.g:658:9: '(' ( formalParameterDecls )? ')' 5118 { 5119 dbg.location(658,9); 5120 match(input,LPAREN,FOLLOW_LPAREN_in_formalParameters2902); if (state.failed) return ; 5121 dbg.location(659,9); 5122 // src/com/google/doclava/parser/Java.g:659:9: ( formalParameterDecls )? 5123 int alt69=2; 5124 try { dbg.enterSubRule(69); 5125 try { dbg.enterDecision(69, decisionCanBacktrack[69]); 5126 5127 int LA69_0 = input.LA(1); 5128 5129 if ( (LA69_0==IDENTIFIER||LA69_0==BOOLEAN||LA69_0==BYTE||LA69_0==CHAR||LA69_0==DOUBLE||LA69_0==FINAL||LA69_0==FLOAT||LA69_0==INT||LA69_0==LONG||LA69_0==SHORT||LA69_0==MONKEYS_AT) ) { 5130 alt69=1; 5131 } 5132 } finally {dbg.exitDecision(69);} 5133 5134 switch (alt69) { 5135 case 1 : 5136 dbg.enterAlt(1); 5137 5138 // src/com/google/doclava/parser/Java.g:659:10: formalParameterDecls 5139 { 5140 dbg.location(659,10); 5141 pushFollow(FOLLOW_formalParameterDecls_in_formalParameters2913); 5142 formalParameterDecls(); 5143 5144 state._fsp--; 5145 if (state.failed) return ; 5146 5147 } 5148 break; 5149 5150 } 5151 } finally {dbg.exitSubRule(69);} 5152 5153 dbg.location(661,9); 5154 match(input,RPAREN,FOLLOW_RPAREN_in_formalParameters2934); if (state.failed) return ; 5155 5156 } 5157 5158 } 5159 catch (RecognitionException re) { 5160 reportError(re); 5161 recover(input,re); 5162 } 5163 finally { 5164 if ( state.backtracking>0 ) { memoize(input, 38, formalParameters_StartIndex); } 5165 } 5166 dbg.location(662, 5); 5167 5168 } 5169 finally { 5170 dbg.exitRule(getGrammarFileName(), "formalParameters"); 5171 decRuleLevel(); 5172 if ( getRuleLevel()==0 ) {dbg.terminate();} 5173 } 5174 5175 return ; 5176 } 5177 // $ANTLR end "formalParameters" 5178 5179 5180 // $ANTLR start "formalParameterDecls" 5181 // src/com/google/doclava/parser/Java.g:664:1: formalParameterDecls : ( ellipsisParameterDecl | normalParameterDecl ( ',' normalParameterDecl )* | ( normalParameterDecl ',' )+ ellipsisParameterDecl ); 5182 public final void formalParameterDecls() throws RecognitionException { 5183 int formalParameterDecls_StartIndex = input.index(); 5184 try { dbg.enterRule(getGrammarFileName(), "formalParameterDecls"); 5185 if ( getRuleLevel()==0 ) {dbg.commence();} 5186 incRuleLevel(); 5187 dbg.location(664, 1); 5188 5189 try { 5190 if ( state.backtracking>0 && alreadyParsedRule(input, 39) ) { return ; } 5191 // src/com/google/doclava/parser/Java.g:665:5: ( ellipsisParameterDecl | normalParameterDecl ( ',' normalParameterDecl )* | ( normalParameterDecl ',' )+ ellipsisParameterDecl ) 5192 int alt72=3; 5193 try { dbg.enterDecision(72, decisionCanBacktrack[72]); 5194 5195 switch ( input.LA(1) ) { 5196 case FINAL: 5197 { 5198 int LA72_1 = input.LA(2); 5199 5200 if ( (synpred96_Java()) ) { 5201 alt72=1; 5202 } 5203 else if ( (synpred98_Java()) ) { 5204 alt72=2; 5205 } 5206 else if ( (true) ) { 5207 alt72=3; 5208 } 5209 else { 5210 if (state.backtracking>0) {state.failed=true; return ;} 5211 NoViableAltException nvae = 5212 new NoViableAltException("", 72, 1, input); 5213 5214 dbg.recognitionException(nvae); 5215 throw nvae; 5216 } 5217 } 5218 break; 5219 case MONKEYS_AT: 5220 { 5221 int LA72_2 = input.LA(2); 5222 5223 if ( (synpred96_Java()) ) { 5224 alt72=1; 5225 } 5226 else if ( (synpred98_Java()) ) { 5227 alt72=2; 5228 } 5229 else if ( (true) ) { 5230 alt72=3; 5231 } 5232 else { 5233 if (state.backtracking>0) {state.failed=true; return ;} 5234 NoViableAltException nvae = 5235 new NoViableAltException("", 72, 2, input); 5236 5237 dbg.recognitionException(nvae); 5238 throw nvae; 5239 } 5240 } 5241 break; 5242 case IDENTIFIER: 5243 { 5244 int LA72_3 = input.LA(2); 5245 5246 if ( (synpred96_Java()) ) { 5247 alt72=1; 5248 } 5249 else if ( (synpred98_Java()) ) { 5250 alt72=2; 5251 } 5252 else if ( (true) ) { 5253 alt72=3; 5254 } 5255 else { 5256 if (state.backtracking>0) {state.failed=true; return ;} 5257 NoViableAltException nvae = 5258 new NoViableAltException("", 72, 3, input); 5259 5260 dbg.recognitionException(nvae); 5261 throw nvae; 5262 } 5263 } 5264 break; 5265 case BOOLEAN: 5266 case BYTE: 5267 case CHAR: 5268 case DOUBLE: 5269 case FLOAT: 5270 case INT: 5271 case LONG: 5272 case SHORT: 5273 { 5274 int LA72_4 = input.LA(2); 5275 5276 if ( (synpred96_Java()) ) { 5277 alt72=1; 5278 } 5279 else if ( (synpred98_Java()) ) { 5280 alt72=2; 5281 } 5282 else if ( (true) ) { 5283 alt72=3; 5284 } 5285 else { 5286 if (state.backtracking>0) {state.failed=true; return ;} 5287 NoViableAltException nvae = 5288 new NoViableAltException("", 72, 4, input); 5289 5290 dbg.recognitionException(nvae); 5291 throw nvae; 5292 } 5293 } 5294 break; 5295 default: 5296 if (state.backtracking>0) {state.failed=true; return ;} 5297 NoViableAltException nvae = 5298 new NoViableAltException("", 72, 0, input); 5299 5300 dbg.recognitionException(nvae); 5301 throw nvae; 5302 } 5303 5304 } finally {dbg.exitDecision(72);} 5305 5306 switch (alt72) { 5307 case 1 : 5308 dbg.enterAlt(1); 5309 5310 // src/com/google/doclava/parser/Java.g:665:9: ellipsisParameterDecl 5311 { 5312 dbg.location(665,9); 5313 pushFollow(FOLLOW_ellipsisParameterDecl_in_formalParameterDecls2953); 5314 ellipsisParameterDecl(); 5315 5316 state._fsp--; 5317 if (state.failed) return ; 5318 5319 } 5320 break; 5321 case 2 : 5322 dbg.enterAlt(2); 5323 5324 // src/com/google/doclava/parser/Java.g:666:9: normalParameterDecl ( ',' normalParameterDecl )* 5325 { 5326 dbg.location(666,9); 5327 pushFollow(FOLLOW_normalParameterDecl_in_formalParameterDecls2963); 5328 normalParameterDecl(); 5329 5330 state._fsp--; 5331 if (state.failed) return ; 5332 dbg.location(667,9); 5333 // src/com/google/doclava/parser/Java.g:667:9: ( ',' normalParameterDecl )* 5334 try { dbg.enterSubRule(70); 5335 5336 loop70: 5337 do { 5338 int alt70=2; 5339 try { dbg.enterDecision(70, decisionCanBacktrack[70]); 5340 5341 int LA70_0 = input.LA(1); 5342 5343 if ( (LA70_0==COMMA) ) { 5344 alt70=1; 5345 } 5346 5347 5348 } finally {dbg.exitDecision(70);} 5349 5350 switch (alt70) { 5351 case 1 : 5352 dbg.enterAlt(1); 5353 5354 // src/com/google/doclava/parser/Java.g:667:10: ',' normalParameterDecl 5355 { 5356 dbg.location(667,10); 5357 match(input,COMMA,FOLLOW_COMMA_in_formalParameterDecls2974); if (state.failed) return ; 5358 dbg.location(667,14); 5359 pushFollow(FOLLOW_normalParameterDecl_in_formalParameterDecls2976); 5360 normalParameterDecl(); 5361 5362 state._fsp--; 5363 if (state.failed) return ; 5364 5365 } 5366 break; 5367 5368 default : 5369 break loop70; 5370 } 5371 } while (true); 5372 } finally {dbg.exitSubRule(70);} 5373 5374 5375 } 5376 break; 5377 case 3 : 5378 dbg.enterAlt(3); 5379 5380 // src/com/google/doclava/parser/Java.g:669:9: ( normalParameterDecl ',' )+ ellipsisParameterDecl 5381 { 5382 dbg.location(669,9); 5383 // src/com/google/doclava/parser/Java.g:669:9: ( normalParameterDecl ',' )+ 5384 int cnt71=0; 5385 try { dbg.enterSubRule(71); 5386 5387 loop71: 5388 do { 5389 int alt71=2; 5390 try { dbg.enterDecision(71, decisionCanBacktrack[71]); 5391 5392 switch ( input.LA(1) ) { 5393 case FINAL: 5394 { 5395 int LA71_1 = input.LA(2); 5396 5397 if ( (synpred99_Java()) ) { 5398 alt71=1; 5399 } 5400 5401 5402 } 5403 break; 5404 case MONKEYS_AT: 5405 { 5406 int LA71_2 = input.LA(2); 5407 5408 if ( (synpred99_Java()) ) { 5409 alt71=1; 5410 } 5411 5412 5413 } 5414 break; 5415 case IDENTIFIER: 5416 { 5417 int LA71_3 = input.LA(2); 5418 5419 if ( (synpred99_Java()) ) { 5420 alt71=1; 5421 } 5422 5423 5424 } 5425 break; 5426 case BOOLEAN: 5427 case BYTE: 5428 case CHAR: 5429 case DOUBLE: 5430 case FLOAT: 5431 case INT: 5432 case LONG: 5433 case SHORT: 5434 { 5435 int LA71_4 = input.LA(2); 5436 5437 if ( (synpred99_Java()) ) { 5438 alt71=1; 5439 } 5440 5441 5442 } 5443 break; 5444 5445 } 5446 5447 } finally {dbg.exitDecision(71);} 5448 5449 switch (alt71) { 5450 case 1 : 5451 dbg.enterAlt(1); 5452 5453 // src/com/google/doclava/parser/Java.g:669:10: normalParameterDecl ',' 5454 { 5455 dbg.location(669,10); 5456 pushFollow(FOLLOW_normalParameterDecl_in_formalParameterDecls2998); 5457 normalParameterDecl(); 5458 5459 state._fsp--; 5460 if (state.failed) return ; 5461 dbg.location(670,9); 5462 match(input,COMMA,FOLLOW_COMMA_in_formalParameterDecls3008); if (state.failed) return ; 5463 5464 } 5465 break; 5466 5467 default : 5468 if ( cnt71 >= 1 ) break loop71; 5469 if (state.backtracking>0) {state.failed=true; return ;} 5470 EarlyExitException eee = 5471 new EarlyExitException(71, input); 5472 dbg.recognitionException(eee); 5473 5474 throw eee; 5475 } 5476 cnt71++; 5477 } while (true); 5478 } finally {dbg.exitSubRule(71);} 5479 5480 dbg.location(672,9); 5481 pushFollow(FOLLOW_ellipsisParameterDecl_in_formalParameterDecls3029); 5482 ellipsisParameterDecl(); 5483 5484 state._fsp--; 5485 if (state.failed) return ; 5486 5487 } 5488 break; 5489 5490 } 5491 } 5492 catch (RecognitionException re) { 5493 reportError(re); 5494 recover(input,re); 5495 } 5496 finally { 5497 if ( state.backtracking>0 ) { memoize(input, 39, formalParameterDecls_StartIndex); } 5498 } 5499 dbg.location(673, 5); 5500 5501 } 5502 finally { 5503 dbg.exitRule(getGrammarFileName(), "formalParameterDecls"); 5504 decRuleLevel(); 5505 if ( getRuleLevel()==0 ) {dbg.terminate();} 5506 } 5507 5508 return ; 5509 } 5510 // $ANTLR end "formalParameterDecls" 5511 5512 5513 // $ANTLR start "normalParameterDecl" 5514 // src/com/google/doclava/parser/Java.g:675:1: normalParameterDecl : variableModifiers type IDENTIFIER ( '[' ']' )* ; 5515 public final void normalParameterDecl() throws RecognitionException { 5516 int normalParameterDecl_StartIndex = input.index(); 5517 try { dbg.enterRule(getGrammarFileName(), "normalParameterDecl"); 5518 if ( getRuleLevel()==0 ) {dbg.commence();} 5519 incRuleLevel(); 5520 dbg.location(675, 1); 5521 5522 try { 5523 if ( state.backtracking>0 && alreadyParsedRule(input, 40) ) { return ; } 5524 // src/com/google/doclava/parser/Java.g:676:5: ( variableModifiers type IDENTIFIER ( '[' ']' )* ) 5525 dbg.enterAlt(1); 5526 5527 // src/com/google/doclava/parser/Java.g:676:9: variableModifiers type IDENTIFIER ( '[' ']' )* 5528 { 5529 dbg.location(676,9); 5530 pushFollow(FOLLOW_variableModifiers_in_normalParameterDecl3048); 5531 variableModifiers(); 5532 5533 state._fsp--; 5534 if (state.failed) return ; 5535 dbg.location(676,27); 5536 pushFollow(FOLLOW_type_in_normalParameterDecl3050); 5537 type(); 5538 5539 state._fsp--; 5540 if (state.failed) return ; 5541 dbg.location(676,32); 5542 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_normalParameterDecl3052); if (state.failed) return ; 5543 dbg.location(677,9); 5544 // src/com/google/doclava/parser/Java.g:677:9: ( '[' ']' )* 5545 try { dbg.enterSubRule(73); 5546 5547 loop73: 5548 do { 5549 int alt73=2; 5550 try { dbg.enterDecision(73, decisionCanBacktrack[73]); 5551 5552 int LA73_0 = input.LA(1); 5553 5554 if ( (LA73_0==LBRACKET) ) { 5555 alt73=1; 5556 } 5557 5558 5559 } finally {dbg.exitDecision(73);} 5560 5561 switch (alt73) { 5562 case 1 : 5563 dbg.enterAlt(1); 5564 5565 // src/com/google/doclava/parser/Java.g:677:10: '[' ']' 5566 { 5567 dbg.location(677,10); 5568 match(input,LBRACKET,FOLLOW_LBRACKET_in_normalParameterDecl3063); if (state.failed) return ; 5569 dbg.location(677,14); 5570 match(input,RBRACKET,FOLLOW_RBRACKET_in_normalParameterDecl3065); if (state.failed) return ; 5571 5572 } 5573 break; 5574 5575 default : 5576 break loop73; 5577 } 5578 } while (true); 5579 } finally {dbg.exitSubRule(73);} 5580 5581 5582 } 5583 5584 } 5585 catch (RecognitionException re) { 5586 reportError(re); 5587 recover(input,re); 5588 } 5589 finally { 5590 if ( state.backtracking>0 ) { memoize(input, 40, normalParameterDecl_StartIndex); } 5591 } 5592 dbg.location(679, 5); 5593 5594 } 5595 finally { 5596 dbg.exitRule(getGrammarFileName(), "normalParameterDecl"); 5597 decRuleLevel(); 5598 if ( getRuleLevel()==0 ) {dbg.terminate();} 5599 } 5600 5601 return ; 5602 } 5603 // $ANTLR end "normalParameterDecl" 5604 5605 5606 // $ANTLR start "ellipsisParameterDecl" 5607 // src/com/google/doclava/parser/Java.g:681:1: ellipsisParameterDecl : variableModifiers type '...' IDENTIFIER ; 5608 public final void ellipsisParameterDecl() throws RecognitionException { 5609 int ellipsisParameterDecl_StartIndex = input.index(); 5610 try { dbg.enterRule(getGrammarFileName(), "ellipsisParameterDecl"); 5611 if ( getRuleLevel()==0 ) {dbg.commence();} 5612 incRuleLevel(); 5613 dbg.location(681, 1); 5614 5615 try { 5616 if ( state.backtracking>0 && alreadyParsedRule(input, 41) ) { return ; } 5617 // src/com/google/doclava/parser/Java.g:682:5: ( variableModifiers type '...' IDENTIFIER ) 5618 dbg.enterAlt(1); 5619 5620 // src/com/google/doclava/parser/Java.g:682:9: variableModifiers type '...' IDENTIFIER 5621 { 5622 dbg.location(682,9); 5623 pushFollow(FOLLOW_variableModifiers_in_ellipsisParameterDecl3095); 5624 variableModifiers(); 5625 5626 state._fsp--; 5627 if (state.failed) return ; 5628 dbg.location(683,9); 5629 pushFollow(FOLLOW_type_in_ellipsisParameterDecl3105); 5630 type(); 5631 5632 state._fsp--; 5633 if (state.failed) return ; 5634 dbg.location(683,15); 5635 match(input,ELLIPSIS,FOLLOW_ELLIPSIS_in_ellipsisParameterDecl3108); if (state.failed) return ; 5636 dbg.location(684,9); 5637 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_ellipsisParameterDecl3118); if (state.failed) return ; 5638 5639 } 5640 5641 } 5642 catch (RecognitionException re) { 5643 reportError(re); 5644 recover(input,re); 5645 } 5646 finally { 5647 if ( state.backtracking>0 ) { memoize(input, 41, ellipsisParameterDecl_StartIndex); } 5648 } 5649 dbg.location(685, 5); 5650 5651 } 5652 finally { 5653 dbg.exitRule(getGrammarFileName(), "ellipsisParameterDecl"); 5654 decRuleLevel(); 5655 if ( getRuleLevel()==0 ) {dbg.terminate();} 5656 } 5657 5658 return ; 5659 } 5660 // $ANTLR end "ellipsisParameterDecl" 5661 5662 5663 // $ANTLR start "explicitConstructorInvocation" 5664 // src/com/google/doclava/parser/Java.g:688:1: explicitConstructorInvocation : ( ( nonWildcardTypeArguments )? ( 'this' | 'super' ) arguments ';' | primary '.' ( nonWildcardTypeArguments )? 'super' arguments ';' ); 5665 public final void explicitConstructorInvocation() throws RecognitionException { 5666 int explicitConstructorInvocation_StartIndex = input.index(); 5667 try { dbg.enterRule(getGrammarFileName(), "explicitConstructorInvocation"); 5668 if ( getRuleLevel()==0 ) {dbg.commence();} 5669 incRuleLevel(); 5670 dbg.location(688, 1); 5671 5672 try { 5673 if ( state.backtracking>0 && alreadyParsedRule(input, 42) ) { return ; } 5674 // src/com/google/doclava/parser/Java.g:689:5: ( ( nonWildcardTypeArguments )? ( 'this' | 'super' ) arguments ';' | primary '.' ( nonWildcardTypeArguments )? 'super' arguments ';' ) 5675 int alt76=2; 5676 try { dbg.enterDecision(76, decisionCanBacktrack[76]); 5677 5678 try { 5679 isCyclicDecision = true; 5680 alt76 = dfa76.predict(input); 5681 } 5682 catch (NoViableAltException nvae) { 5683 dbg.recognitionException(nvae); 5684 throw nvae; 5685 } 5686 } finally {dbg.exitDecision(76);} 5687 5688 switch (alt76) { 5689 case 1 : 5690 dbg.enterAlt(1); 5691 5692 // src/com/google/doclava/parser/Java.g:689:9: ( nonWildcardTypeArguments )? ( 'this' | 'super' ) arguments ';' 5693 { 5694 dbg.location(689,9); 5695 // src/com/google/doclava/parser/Java.g:689:9: ( nonWildcardTypeArguments )? 5696 int alt74=2; 5697 try { dbg.enterSubRule(74); 5698 try { dbg.enterDecision(74, decisionCanBacktrack[74]); 5699 5700 int LA74_0 = input.LA(1); 5701 5702 if ( (LA74_0==LT) ) { 5703 alt74=1; 5704 } 5705 } finally {dbg.exitDecision(74);} 5706 5707 switch (alt74) { 5708 case 1 : 5709 dbg.enterAlt(1); 5710 5711 // src/com/google/doclava/parser/Java.g:689:10: nonWildcardTypeArguments 5712 { 5713 dbg.location(689,10); 5714 pushFollow(FOLLOW_nonWildcardTypeArguments_in_explicitConstructorInvocation3139); 5715 nonWildcardTypeArguments(); 5716 5717 state._fsp--; 5718 if (state.failed) return ; 5719 5720 } 5721 break; 5722 5723 } 5724 } finally {dbg.exitSubRule(74);} 5725 5726 dbg.location(691,9); 5727 if ( input.LA(1)==SUPER||input.LA(1)==THIS ) { 5728 input.consume(); 5729 state.errorRecovery=false;state.failed=false; 5730 } 5731 else { 5732 if (state.backtracking>0) {state.failed=true; return ;} 5733 MismatchedSetException mse = new MismatchedSetException(null,input); 5734 dbg.recognitionException(mse); 5735 throw mse; 5736 } 5737 5738 dbg.location(694,9); 5739 pushFollow(FOLLOW_arguments_in_explicitConstructorInvocation3197); 5740 arguments(); 5741 5742 state._fsp--; 5743 if (state.failed) return ; 5744 dbg.location(694,19); 5745 match(input,SEMI,FOLLOW_SEMI_in_explicitConstructorInvocation3199); if (state.failed) return ; 5746 5747 } 5748 break; 5749 case 2 : 5750 dbg.enterAlt(2); 5751 5752 // src/com/google/doclava/parser/Java.g:696:9: primary '.' ( nonWildcardTypeArguments )? 'super' arguments ';' 5753 { 5754 dbg.location(696,9); 5755 pushFollow(FOLLOW_primary_in_explicitConstructorInvocation3210); 5756 primary(); 5757 5758 state._fsp--; 5759 if (state.failed) return ; 5760 dbg.location(697,9); 5761 match(input,DOT,FOLLOW_DOT_in_explicitConstructorInvocation3220); if (state.failed) return ; 5762 dbg.location(698,9); 5763 // src/com/google/doclava/parser/Java.g:698:9: ( nonWildcardTypeArguments )? 5764 int alt75=2; 5765 try { dbg.enterSubRule(75); 5766 try { dbg.enterDecision(75, decisionCanBacktrack[75]); 5767 5768 int LA75_0 = input.LA(1); 5769 5770 if ( (LA75_0==LT) ) { 5771 alt75=1; 5772 } 5773 } finally {dbg.exitDecision(75);} 5774 5775 switch (alt75) { 5776 case 1 : 5777 dbg.enterAlt(1); 5778 5779 // src/com/google/doclava/parser/Java.g:698:10: nonWildcardTypeArguments 5780 { 5781 dbg.location(698,10); 5782 pushFollow(FOLLOW_nonWildcardTypeArguments_in_explicitConstructorInvocation3231); 5783 nonWildcardTypeArguments(); 5784 5785 state._fsp--; 5786 if (state.failed) return ; 5787 5788 } 5789 break; 5790 5791 } 5792 } finally {dbg.exitSubRule(75);} 5793 5794 dbg.location(700,9); 5795 match(input,SUPER,FOLLOW_SUPER_in_explicitConstructorInvocation3252); if (state.failed) return ; 5796 dbg.location(701,9); 5797 pushFollow(FOLLOW_arguments_in_explicitConstructorInvocation3262); 5798 arguments(); 5799 5800 state._fsp--; 5801 if (state.failed) return ; 5802 dbg.location(701,19); 5803 match(input,SEMI,FOLLOW_SEMI_in_explicitConstructorInvocation3264); if (state.failed) return ; 5804 5805 } 5806 break; 5807 5808 } 5809 } 5810 catch (RecognitionException re) { 5811 reportError(re); 5812 recover(input,re); 5813 } 5814 finally { 5815 if ( state.backtracking>0 ) { memoize(input, 42, explicitConstructorInvocation_StartIndex); } 5816 } 5817 dbg.location(702, 5); 5818 5819 } 5820 finally { 5821 dbg.exitRule(getGrammarFileName(), "explicitConstructorInvocation"); 5822 decRuleLevel(); 5823 if ( getRuleLevel()==0 ) {dbg.terminate();} 5824 } 5825 5826 return ; 5827 } 5828 // $ANTLR end "explicitConstructorInvocation" 5829 5830 5831 // $ANTLR start "qualifiedName" 5832 // src/com/google/doclava/parser/Java.g:704:1: qualifiedName : IDENTIFIER ( '.' IDENTIFIER )* ; 5833 public final void qualifiedName() throws RecognitionException { 5834 int qualifiedName_StartIndex = input.index(); 5835 try { dbg.enterRule(getGrammarFileName(), "qualifiedName"); 5836 if ( getRuleLevel()==0 ) {dbg.commence();} 5837 incRuleLevel(); 5838 dbg.location(704, 1); 5839 5840 try { 5841 if ( state.backtracking>0 && alreadyParsedRule(input, 43) ) { return ; } 5842 // src/com/google/doclava/parser/Java.g:705:5: ( IDENTIFIER ( '.' IDENTIFIER )* ) 5843 dbg.enterAlt(1); 5844 5845 // src/com/google/doclava/parser/Java.g:705:9: IDENTIFIER ( '.' IDENTIFIER )* 5846 { 5847 dbg.location(705,9); 5848 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_qualifiedName3283); if (state.failed) return ; 5849 dbg.location(706,9); 5850 // src/com/google/doclava/parser/Java.g:706:9: ( '.' IDENTIFIER )* 5851 try { dbg.enterSubRule(77); 5852 5853 loop77: 5854 do { 5855 int alt77=2; 5856 try { dbg.enterDecision(77, decisionCanBacktrack[77]); 5857 5858 int LA77_0 = input.LA(1); 5859 5860 if ( (LA77_0==DOT) ) { 5861 alt77=1; 5862 } 5863 5864 5865 } finally {dbg.exitDecision(77);} 5866 5867 switch (alt77) { 5868 case 1 : 5869 dbg.enterAlt(1); 5870 5871 // src/com/google/doclava/parser/Java.g:706:10: '.' IDENTIFIER 5872 { 5873 dbg.location(706,10); 5874 match(input,DOT,FOLLOW_DOT_in_qualifiedName3294); if (state.failed) return ; 5875 dbg.location(706,14); 5876 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_qualifiedName3296); if (state.failed) return ; 5877 5878 } 5879 break; 5880 5881 default : 5882 break loop77; 5883 } 5884 } while (true); 5885 } finally {dbg.exitSubRule(77);} 5886 5887 5888 } 5889 5890 } 5891 catch (RecognitionException re) { 5892 reportError(re); 5893 recover(input,re); 5894 } 5895 finally { 5896 if ( state.backtracking>0 ) { memoize(input, 43, qualifiedName_StartIndex); } 5897 } 5898 dbg.location(708, 5); 5899 5900 } 5901 finally { 5902 dbg.exitRule(getGrammarFileName(), "qualifiedName"); 5903 decRuleLevel(); 5904 if ( getRuleLevel()==0 ) {dbg.terminate();} 5905 } 5906 5907 return ; 5908 } 5909 // $ANTLR end "qualifiedName" 5910 5911 5912 // $ANTLR start "annotations" 5913 // src/com/google/doclava/parser/Java.g:710:1: annotations : ( annotation )+ ; 5914 public final void annotations() throws RecognitionException { 5915 int annotations_StartIndex = input.index(); 5916 try { dbg.enterRule(getGrammarFileName(), "annotations"); 5917 if ( getRuleLevel()==0 ) {dbg.commence();} 5918 incRuleLevel(); 5919 dbg.location(710, 1); 5920 5921 try { 5922 if ( state.backtracking>0 && alreadyParsedRule(input, 44) ) { return ; } 5923 // src/com/google/doclava/parser/Java.g:711:5: ( ( annotation )+ ) 5924 dbg.enterAlt(1); 5925 5926 // src/com/google/doclava/parser/Java.g:711:9: ( annotation )+ 5927 { 5928 dbg.location(711,9); 5929 // src/com/google/doclava/parser/Java.g:711:9: ( annotation )+ 5930 int cnt78=0; 5931 try { dbg.enterSubRule(78); 5932 5933 loop78: 5934 do { 5935 int alt78=2; 5936 try { dbg.enterDecision(78, decisionCanBacktrack[78]); 5937 5938 int LA78_0 = input.LA(1); 5939 5940 if ( (LA78_0==MONKEYS_AT) ) { 5941 alt78=1; 5942 } 5943 5944 5945 } finally {dbg.exitDecision(78);} 5946 5947 switch (alt78) { 5948 case 1 : 5949 dbg.enterAlt(1); 5950 5951 // src/com/google/doclava/parser/Java.g:711:10: annotation 5952 { 5953 dbg.location(711,10); 5954 pushFollow(FOLLOW_annotation_in_annotations3327); 5955 annotation(); 5956 5957 state._fsp--; 5958 if (state.failed) return ; 5959 5960 } 5961 break; 5962 5963 default : 5964 if ( cnt78 >= 1 ) break loop78; 5965 if (state.backtracking>0) {state.failed=true; return ;} 5966 EarlyExitException eee = 5967 new EarlyExitException(78, input); 5968 dbg.recognitionException(eee); 5969 5970 throw eee; 5971 } 5972 cnt78++; 5973 } while (true); 5974 } finally {dbg.exitSubRule(78);} 5975 5976 5977 } 5978 5979 } 5980 catch (RecognitionException re) { 5981 reportError(re); 5982 recover(input,re); 5983 } 5984 finally { 5985 if ( state.backtracking>0 ) { memoize(input, 44, annotations_StartIndex); } 5986 } 5987 dbg.location(713, 5); 5988 5989 } 5990 finally { 5991 dbg.exitRule(getGrammarFileName(), "annotations"); 5992 decRuleLevel(); 5993 if ( getRuleLevel()==0 ) {dbg.terminate();} 5994 } 5995 5996 return ; 5997 } 5998 // $ANTLR end "annotations" 5999 6000 6001 // $ANTLR start "annotation" 6002 // src/com/google/doclava/parser/Java.g:715:1: annotation : '@' qualifiedName ( '(' ( elementValuePairs | elementValue )? ')' )? ; 6003 public final void annotation() throws RecognitionException { 6004 int annotation_StartIndex = input.index(); 6005 try { dbg.enterRule(getGrammarFileName(), "annotation"); 6006 if ( getRuleLevel()==0 ) {dbg.commence();} 6007 incRuleLevel(); 6008 dbg.location(715, 1); 6009 6010 try { 6011 if ( state.backtracking>0 && alreadyParsedRule(input, 45) ) { return ; } 6012 // src/com/google/doclava/parser/Java.g:720:5: ( '@' qualifiedName ( '(' ( elementValuePairs | elementValue )? ')' )? ) 6013 dbg.enterAlt(1); 6014 6015 // src/com/google/doclava/parser/Java.g:720:9: '@' qualifiedName ( '(' ( elementValuePairs | elementValue )? ')' )? 6016 { 6017 dbg.location(720,9); 6018 match(input,MONKEYS_AT,FOLLOW_MONKEYS_AT_in_annotation3359); if (state.failed) return ; 6019 dbg.location(720,13); 6020 pushFollow(FOLLOW_qualifiedName_in_annotation3361); 6021 qualifiedName(); 6022 6023 state._fsp--; 6024 if (state.failed) return ; 6025 dbg.location(721,9); 6026 // src/com/google/doclava/parser/Java.g:721:9: ( '(' ( elementValuePairs | elementValue )? ')' )? 6027 int alt80=2; 6028 try { dbg.enterSubRule(80); 6029 try { dbg.enterDecision(80, decisionCanBacktrack[80]); 6030 6031 int LA80_0 = input.LA(1); 6032 6033 if ( (LA80_0==LPAREN) ) { 6034 alt80=1; 6035 } 6036 } finally {dbg.exitDecision(80);} 6037 6038 switch (alt80) { 6039 case 1 : 6040 dbg.enterAlt(1); 6041 6042 // src/com/google/doclava/parser/Java.g:721:13: '(' ( elementValuePairs | elementValue )? ')' 6043 { 6044 dbg.location(721,13); 6045 match(input,LPAREN,FOLLOW_LPAREN_in_annotation3375); if (state.failed) return ; 6046 dbg.location(722,19); 6047 // src/com/google/doclava/parser/Java.g:722:19: ( elementValuePairs | elementValue )? 6048 int alt79=3; 6049 try { dbg.enterSubRule(79); 6050 try { dbg.enterDecision(79, decisionCanBacktrack[79]); 6051 6052 int LA79_0 = input.LA(1); 6053 6054 if ( (LA79_0==IDENTIFIER) ) { 6055 int LA79_1 = input.LA(2); 6056 6057 if ( (LA79_1==EQ) ) { 6058 alt79=1; 6059 } 6060 else if ( (LA79_1==INSTANCEOF||(LA79_1>=LPAREN && LA79_1<=RPAREN)||LA79_1==LBRACKET||LA79_1==DOT||LA79_1==QUES||(LA79_1>=EQEQ && LA79_1<=PERCENT)||(LA79_1>=BANGEQ && LA79_1<=LT)) ) { 6061 alt79=2; 6062 } 6063 } 6064 else if ( ((LA79_0>=INTLITERAL && LA79_0<=NULL)||LA79_0==BOOLEAN||LA79_0==BYTE||LA79_0==CHAR||LA79_0==DOUBLE||LA79_0==FLOAT||LA79_0==INT||LA79_0==LONG||LA79_0==NEW||LA79_0==SHORT||LA79_0==SUPER||LA79_0==THIS||LA79_0==VOID||LA79_0==LPAREN||LA79_0==LBRACE||(LA79_0>=BANG && LA79_0<=TILDE)||(LA79_0>=PLUSPLUS && LA79_0<=SUB)||LA79_0==MONKEYS_AT) ) { 6065 alt79=2; 6066 } 6067 } finally {dbg.exitDecision(79);} 6068 6069 switch (alt79) { 6070 case 1 : 6071 dbg.enterAlt(1); 6072 6073 // src/com/google/doclava/parser/Java.g:722:23: elementValuePairs 6074 { 6075 dbg.location(722,23); 6076 pushFollow(FOLLOW_elementValuePairs_in_annotation3399); 6077 elementValuePairs(); 6078 6079 state._fsp--; 6080 if (state.failed) return ; 6081 6082 } 6083 break; 6084 case 2 : 6085 dbg.enterAlt(2); 6086 6087 // src/com/google/doclava/parser/Java.g:723:23: elementValue 6088 { 6089 dbg.location(723,23); 6090 pushFollow(FOLLOW_elementValue_in_annotation3423); 6091 elementValue(); 6092 6093 state._fsp--; 6094 if (state.failed) return ; 6095 6096 } 6097 break; 6098 6099 } 6100 } finally {dbg.exitSubRule(79);} 6101 6102 dbg.location(725,13); 6103 match(input,RPAREN,FOLLOW_RPAREN_in_annotation3458); if (state.failed) return ; 6104 6105 } 6106 break; 6107 6108 } 6109 } finally {dbg.exitSubRule(80);} 6110 6111 6112 } 6113 6114 } 6115 catch (RecognitionException re) { 6116 reportError(re); 6117 recover(input,re); 6118 } 6119 finally { 6120 if ( state.backtracking>0 ) { memoize(input, 45, annotation_StartIndex); } 6121 } 6122 dbg.location(727, 5); 6123 6124 } 6125 finally { 6126 dbg.exitRule(getGrammarFileName(), "annotation"); 6127 decRuleLevel(); 6128 if ( getRuleLevel()==0 ) {dbg.terminate();} 6129 } 6130 6131 return ; 6132 } 6133 // $ANTLR end "annotation" 6134 6135 6136 // $ANTLR start "elementValuePairs" 6137 // src/com/google/doclava/parser/Java.g:729:1: elementValuePairs : elementValuePair ( ',' elementValuePair )* ; 6138 public final void elementValuePairs() throws RecognitionException { 6139 int elementValuePairs_StartIndex = input.index(); 6140 try { dbg.enterRule(getGrammarFileName(), "elementValuePairs"); 6141 if ( getRuleLevel()==0 ) {dbg.commence();} 6142 incRuleLevel(); 6143 dbg.location(729, 1); 6144 6145 try { 6146 if ( state.backtracking>0 && alreadyParsedRule(input, 46) ) { return ; } 6147 // src/com/google/doclava/parser/Java.g:730:5: ( elementValuePair ( ',' elementValuePair )* ) 6148 dbg.enterAlt(1); 6149 6150 // src/com/google/doclava/parser/Java.g:730:9: elementValuePair ( ',' elementValuePair )* 6151 { 6152 dbg.location(730,9); 6153 pushFollow(FOLLOW_elementValuePair_in_elementValuePairs3488); 6154 elementValuePair(); 6155 6156 state._fsp--; 6157 if (state.failed) return ; 6158 dbg.location(731,9); 6159 // src/com/google/doclava/parser/Java.g:731:9: ( ',' elementValuePair )* 6160 try { dbg.enterSubRule(81); 6161 6162 loop81: 6163 do { 6164 int alt81=2; 6165 try { dbg.enterDecision(81, decisionCanBacktrack[81]); 6166 6167 int LA81_0 = input.LA(1); 6168 6169 if ( (LA81_0==COMMA) ) { 6170 alt81=1; 6171 } 6172 6173 6174 } finally {dbg.exitDecision(81);} 6175 6176 switch (alt81) { 6177 case 1 : 6178 dbg.enterAlt(1); 6179 6180 // src/com/google/doclava/parser/Java.g:731:10: ',' elementValuePair 6181 { 6182 dbg.location(731,10); 6183 match(input,COMMA,FOLLOW_COMMA_in_elementValuePairs3499); if (state.failed) return ; 6184 dbg.location(731,14); 6185 pushFollow(FOLLOW_elementValuePair_in_elementValuePairs3501); 6186 elementValuePair(); 6187 6188 state._fsp--; 6189 if (state.failed) return ; 6190 6191 } 6192 break; 6193 6194 default : 6195 break loop81; 6196 } 6197 } while (true); 6198 } finally {dbg.exitSubRule(81);} 6199 6200 6201 } 6202 6203 } 6204 catch (RecognitionException re) { 6205 reportError(re); 6206 recover(input,re); 6207 } 6208 finally { 6209 if ( state.backtracking>0 ) { memoize(input, 46, elementValuePairs_StartIndex); } 6210 } 6211 dbg.location(733, 5); 6212 6213 } 6214 finally { 6215 dbg.exitRule(getGrammarFileName(), "elementValuePairs"); 6216 decRuleLevel(); 6217 if ( getRuleLevel()==0 ) {dbg.terminate();} 6218 } 6219 6220 return ; 6221 } 6222 // $ANTLR end "elementValuePairs" 6223 6224 6225 // $ANTLR start "elementValuePair" 6226 // src/com/google/doclava/parser/Java.g:735:1: elementValuePair : IDENTIFIER '=' elementValue ; 6227 public final void elementValuePair() throws RecognitionException { 6228 int elementValuePair_StartIndex = input.index(); 6229 try { dbg.enterRule(getGrammarFileName(), "elementValuePair"); 6230 if ( getRuleLevel()==0 ) {dbg.commence();} 6231 incRuleLevel(); 6232 dbg.location(735, 1); 6233 6234 try { 6235 if ( state.backtracking>0 && alreadyParsedRule(input, 47) ) { return ; } 6236 // src/com/google/doclava/parser/Java.g:736:5: ( IDENTIFIER '=' elementValue ) 6237 dbg.enterAlt(1); 6238 6239 // src/com/google/doclava/parser/Java.g:736:9: IDENTIFIER '=' elementValue 6240 { 6241 dbg.location(736,9); 6242 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_elementValuePair3531); if (state.failed) return ; 6243 dbg.location(736,20); 6244 match(input,EQ,FOLLOW_EQ_in_elementValuePair3533); if (state.failed) return ; 6245 dbg.location(736,24); 6246 pushFollow(FOLLOW_elementValue_in_elementValuePair3535); 6247 elementValue(); 6248 6249 state._fsp--; 6250 if (state.failed) return ; 6251 6252 } 6253 6254 } 6255 catch (RecognitionException re) { 6256 reportError(re); 6257 recover(input,re); 6258 } 6259 finally { 6260 if ( state.backtracking>0 ) { memoize(input, 47, elementValuePair_StartIndex); } 6261 } 6262 dbg.location(737, 5); 6263 6264 } 6265 finally { 6266 dbg.exitRule(getGrammarFileName(), "elementValuePair"); 6267 decRuleLevel(); 6268 if ( getRuleLevel()==0 ) {dbg.terminate();} 6269 } 6270 6271 return ; 6272 } 6273 // $ANTLR end "elementValuePair" 6274 6275 6276 // $ANTLR start "elementValue" 6277 // src/com/google/doclava/parser/Java.g:739:1: elementValue : ( conditionalExpression | annotation | elementValueArrayInitializer ); 6278 public final void elementValue() throws RecognitionException { 6279 int elementValue_StartIndex = input.index(); 6280 try { dbg.enterRule(getGrammarFileName(), "elementValue"); 6281 if ( getRuleLevel()==0 ) {dbg.commence();} 6282 incRuleLevel(); 6283 dbg.location(739, 1); 6284 6285 try { 6286 if ( state.backtracking>0 && alreadyParsedRule(input, 48) ) { return ; } 6287 // src/com/google/doclava/parser/Java.g:740:5: ( conditionalExpression | annotation | elementValueArrayInitializer ) 6288 int alt82=3; 6289 try { dbg.enterDecision(82, decisionCanBacktrack[82]); 6290 6291 switch ( input.LA(1) ) { 6292 case IDENTIFIER: 6293 case INTLITERAL: 6294 case LONGLITERAL: 6295 case FLOATLITERAL: 6296 case DOUBLELITERAL: 6297 case CHARLITERAL: 6298 case STRINGLITERAL: 6299 case TRUE: 6300 case FALSE: 6301 case NULL: 6302 case BOOLEAN: 6303 case BYTE: 6304 case CHAR: 6305 case DOUBLE: 6306 case FLOAT: 6307 case INT: 6308 case LONG: 6309 case NEW: 6310 case SHORT: 6311 case SUPER: 6312 case THIS: 6313 case VOID: 6314 case LPAREN: 6315 case BANG: 6316 case TILDE: 6317 case PLUSPLUS: 6318 case SUBSUB: 6319 case PLUS: 6320 case SUB: 6321 { 6322 alt82=1; 6323 } 6324 break; 6325 case MONKEYS_AT: 6326 { 6327 alt82=2; 6328 } 6329 break; 6330 case LBRACE: 6331 { 6332 alt82=3; 6333 } 6334 break; 6335 default: 6336 if (state.backtracking>0) {state.failed=true; return ;} 6337 NoViableAltException nvae = 6338 new NoViableAltException("", 82, 0, input); 6339 6340 dbg.recognitionException(nvae); 6341 throw nvae; 6342 } 6343 6344 } finally {dbg.exitDecision(82);} 6345 6346 switch (alt82) { 6347 case 1 : 6348 dbg.enterAlt(1); 6349 6350 // src/com/google/doclava/parser/Java.g:740:9: conditionalExpression 6351 { 6352 dbg.location(740,9); 6353 pushFollow(FOLLOW_conditionalExpression_in_elementValue3554); 6354 conditionalExpression(); 6355 6356 state._fsp--; 6357 if (state.failed) return ; 6358 6359 } 6360 break; 6361 case 2 : 6362 dbg.enterAlt(2); 6363 6364 // src/com/google/doclava/parser/Java.g:741:9: annotation 6365 { 6366 dbg.location(741,9); 6367 pushFollow(FOLLOW_annotation_in_elementValue3564); 6368 annotation(); 6369 6370 state._fsp--; 6371 if (state.failed) return ; 6372 6373 } 6374 break; 6375 case 3 : 6376 dbg.enterAlt(3); 6377 6378 // src/com/google/doclava/parser/Java.g:742:9: elementValueArrayInitializer 6379 { 6380 dbg.location(742,9); 6381 pushFollow(FOLLOW_elementValueArrayInitializer_in_elementValue3574); 6382 elementValueArrayInitializer(); 6383 6384 state._fsp--; 6385 if (state.failed) return ; 6386 6387 } 6388 break; 6389 6390 } 6391 } 6392 catch (RecognitionException re) { 6393 reportError(re); 6394 recover(input,re); 6395 } 6396 finally { 6397 if ( state.backtracking>0 ) { memoize(input, 48, elementValue_StartIndex); } 6398 } 6399 dbg.location(743, 5); 6400 6401 } 6402 finally { 6403 dbg.exitRule(getGrammarFileName(), "elementValue"); 6404 decRuleLevel(); 6405 if ( getRuleLevel()==0 ) {dbg.terminate();} 6406 } 6407 6408 return ; 6409 } 6410 // $ANTLR end "elementValue" 6411 6412 6413 // $ANTLR start "elementValueArrayInitializer" 6414 // src/com/google/doclava/parser/Java.g:745:1: elementValueArrayInitializer : '{' ( elementValue ( ',' elementValue )* )? ( ',' )? '}' ; 6415 public final void elementValueArrayInitializer() throws RecognitionException { 6416 int elementValueArrayInitializer_StartIndex = input.index(); 6417 try { dbg.enterRule(getGrammarFileName(), "elementValueArrayInitializer"); 6418 if ( getRuleLevel()==0 ) {dbg.commence();} 6419 incRuleLevel(); 6420 dbg.location(745, 1); 6421 6422 try { 6423 if ( state.backtracking>0 && alreadyParsedRule(input, 49) ) { return ; } 6424 // src/com/google/doclava/parser/Java.g:746:5: ( '{' ( elementValue ( ',' elementValue )* )? ( ',' )? '}' ) 6425 dbg.enterAlt(1); 6426 6427 // src/com/google/doclava/parser/Java.g:746:9: '{' ( elementValue ( ',' elementValue )* )? ( ',' )? '}' 6428 { 6429 dbg.location(746,9); 6430 match(input,LBRACE,FOLLOW_LBRACE_in_elementValueArrayInitializer3593); if (state.failed) return ; 6431 dbg.location(747,9); 6432 // src/com/google/doclava/parser/Java.g:747:9: ( elementValue ( ',' elementValue )* )? 6433 int alt84=2; 6434 try { dbg.enterSubRule(84); 6435 try { dbg.enterDecision(84, decisionCanBacktrack[84]); 6436 6437 int LA84_0 = input.LA(1); 6438 6439 if ( ((LA84_0>=IDENTIFIER && LA84_0<=NULL)||LA84_0==BOOLEAN||LA84_0==BYTE||LA84_0==CHAR||LA84_0==DOUBLE||LA84_0==FLOAT||LA84_0==INT||LA84_0==LONG||LA84_0==NEW||LA84_0==SHORT||LA84_0==SUPER||LA84_0==THIS||LA84_0==VOID||LA84_0==LPAREN||LA84_0==LBRACE||(LA84_0>=BANG && LA84_0<=TILDE)||(LA84_0>=PLUSPLUS && LA84_0<=SUB)||LA84_0==MONKEYS_AT) ) { 6440 alt84=1; 6441 } 6442 } finally {dbg.exitDecision(84);} 6443 6444 switch (alt84) { 6445 case 1 : 6446 dbg.enterAlt(1); 6447 6448 // src/com/google/doclava/parser/Java.g:747:10: elementValue ( ',' elementValue )* 6449 { 6450 dbg.location(747,10); 6451 pushFollow(FOLLOW_elementValue_in_elementValueArrayInitializer3604); 6452 elementValue(); 6453 6454 state._fsp--; 6455 if (state.failed) return ; 6456 dbg.location(748,13); 6457 // src/com/google/doclava/parser/Java.g:748:13: ( ',' elementValue )* 6458 try { dbg.enterSubRule(83); 6459 6460 loop83: 6461 do { 6462 int alt83=2; 6463 try { dbg.enterDecision(83, decisionCanBacktrack[83]); 6464 6465 int LA83_0 = input.LA(1); 6466 6467 if ( (LA83_0==COMMA) ) { 6468 int LA83_1 = input.LA(2); 6469 6470 if ( ((LA83_1>=IDENTIFIER && LA83_1<=NULL)||LA83_1==BOOLEAN||LA83_1==BYTE||LA83_1==CHAR||LA83_1==DOUBLE||LA83_1==FLOAT||LA83_1==INT||LA83_1==LONG||LA83_1==NEW||LA83_1==SHORT||LA83_1==SUPER||LA83_1==THIS||LA83_1==VOID||LA83_1==LPAREN||LA83_1==LBRACE||(LA83_1>=BANG && LA83_1<=TILDE)||(LA83_1>=PLUSPLUS && LA83_1<=SUB)||LA83_1==MONKEYS_AT) ) { 6471 alt83=1; 6472 } 6473 6474 6475 } 6476 6477 6478 } finally {dbg.exitDecision(83);} 6479 6480 switch (alt83) { 6481 case 1 : 6482 dbg.enterAlt(1); 6483 6484 // src/com/google/doclava/parser/Java.g:748:14: ',' elementValue 6485 { 6486 dbg.location(748,14); 6487 match(input,COMMA,FOLLOW_COMMA_in_elementValueArrayInitializer3619); if (state.failed) return ; 6488 dbg.location(748,18); 6489 pushFollow(FOLLOW_elementValue_in_elementValueArrayInitializer3621); 6490 elementValue(); 6491 6492 state._fsp--; 6493 if (state.failed) return ; 6494 6495 } 6496 break; 6497 6498 default : 6499 break loop83; 6500 } 6501 } while (true); 6502 } finally {dbg.exitSubRule(83);} 6503 6504 6505 } 6506 break; 6507 6508 } 6509 } finally {dbg.exitSubRule(84);} 6510 6511 dbg.location(750,12); 6512 // src/com/google/doclava/parser/Java.g:750:12: ( ',' )? 6513 int alt85=2; 6514 try { dbg.enterSubRule(85); 6515 try { dbg.enterDecision(85, decisionCanBacktrack[85]); 6516 6517 int LA85_0 = input.LA(1); 6518 6519 if ( (LA85_0==COMMA) ) { 6520 alt85=1; 6521 } 6522 } finally {dbg.exitDecision(85);} 6523 6524 switch (alt85) { 6525 case 1 : 6526 dbg.enterAlt(1); 6527 6528 // src/com/google/doclava/parser/Java.g:750:13: ',' 6529 { 6530 dbg.location(750,13); 6531 match(input,COMMA,FOLLOW_COMMA_in_elementValueArrayInitializer3650); if (state.failed) return ; 6532 6533 } 6534 break; 6535 6536 } 6537 } finally {dbg.exitSubRule(85);} 6538 6539 dbg.location(750,19); 6540 match(input,RBRACE,FOLLOW_RBRACE_in_elementValueArrayInitializer3654); if (state.failed) return ; 6541 6542 } 6543 6544 } 6545 catch (RecognitionException re) { 6546 reportError(re); 6547 recover(input,re); 6548 } 6549 finally { 6550 if ( state.backtracking>0 ) { memoize(input, 49, elementValueArrayInitializer_StartIndex); } 6551 } 6552 dbg.location(751, 5); 6553 6554 } 6555 finally { 6556 dbg.exitRule(getGrammarFileName(), "elementValueArrayInitializer"); 6557 decRuleLevel(); 6558 if ( getRuleLevel()==0 ) {dbg.terminate();} 6559 } 6560 6561 return ; 6562 } 6563 // $ANTLR end "elementValueArrayInitializer" 6564 6565 6566 // $ANTLR start "annotationTypeDeclaration" 6567 // src/com/google/doclava/parser/Java.g:754:1: annotationTypeDeclaration : modifiers '@' 'interface' IDENTIFIER annotationTypeBody ; 6568 public final void annotationTypeDeclaration() throws RecognitionException { 6569 int annotationTypeDeclaration_StartIndex = input.index(); 6570 try { dbg.enterRule(getGrammarFileName(), "annotationTypeDeclaration"); 6571 if ( getRuleLevel()==0 ) {dbg.commence();} 6572 incRuleLevel(); 6573 dbg.location(754, 1); 6574 6575 try { 6576 if ( state.backtracking>0 && alreadyParsedRule(input, 50) ) { return ; } 6577 // src/com/google/doclava/parser/Java.g:758:5: ( modifiers '@' 'interface' IDENTIFIER annotationTypeBody ) 6578 dbg.enterAlt(1); 6579 6580 // src/com/google/doclava/parser/Java.g:758:9: modifiers '@' 'interface' IDENTIFIER annotationTypeBody 6581 { 6582 dbg.location(758,9); 6583 pushFollow(FOLLOW_modifiers_in_annotationTypeDeclaration3676); 6584 modifiers(); 6585 6586 state._fsp--; 6587 if (state.failed) return ; 6588 dbg.location(758,19); 6589 match(input,MONKEYS_AT,FOLLOW_MONKEYS_AT_in_annotationTypeDeclaration3678); if (state.failed) return ; 6590 dbg.location(759,9); 6591 match(input,INTERFACE,FOLLOW_INTERFACE_in_annotationTypeDeclaration3688); if (state.failed) return ; 6592 dbg.location(760,9); 6593 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_annotationTypeDeclaration3698); if (state.failed) return ; 6594 dbg.location(761,9); 6595 pushFollow(FOLLOW_annotationTypeBody_in_annotationTypeDeclaration3708); 6596 annotationTypeBody(); 6597 6598 state._fsp--; 6599 if (state.failed) return ; 6600 6601 } 6602 6603 } 6604 catch (RecognitionException re) { 6605 reportError(re); 6606 recover(input,re); 6607 } 6608 finally { 6609 if ( state.backtracking>0 ) { memoize(input, 50, annotationTypeDeclaration_StartIndex); } 6610 } 6611 dbg.location(762, 5); 6612 6613 } 6614 finally { 6615 dbg.exitRule(getGrammarFileName(), "annotationTypeDeclaration"); 6616 decRuleLevel(); 6617 if ( getRuleLevel()==0 ) {dbg.terminate();} 6618 } 6619 6620 return ; 6621 } 6622 // $ANTLR end "annotationTypeDeclaration" 6623 6624 6625 // $ANTLR start "annotationTypeBody" 6626 // src/com/google/doclava/parser/Java.g:765:1: annotationTypeBody : '{' ( annotationTypeElementDeclaration )* '}' ; 6627 public final void annotationTypeBody() throws RecognitionException { 6628 int annotationTypeBody_StartIndex = input.index(); 6629 try { dbg.enterRule(getGrammarFileName(), "annotationTypeBody"); 6630 if ( getRuleLevel()==0 ) {dbg.commence();} 6631 incRuleLevel(); 6632 dbg.location(765, 1); 6633 6634 try { 6635 if ( state.backtracking>0 && alreadyParsedRule(input, 51) ) { return ; } 6636 // src/com/google/doclava/parser/Java.g:766:5: ( '{' ( annotationTypeElementDeclaration )* '}' ) 6637 dbg.enterAlt(1); 6638 6639 // src/com/google/doclava/parser/Java.g:766:9: '{' ( annotationTypeElementDeclaration )* '}' 6640 { 6641 dbg.location(766,9); 6642 match(input,LBRACE,FOLLOW_LBRACE_in_annotationTypeBody3728); if (state.failed) return ; 6643 dbg.location(767,9); 6644 // src/com/google/doclava/parser/Java.g:767:9: ( annotationTypeElementDeclaration )* 6645 try { dbg.enterSubRule(86); 6646 6647 loop86: 6648 do { 6649 int alt86=2; 6650 try { dbg.enterDecision(86, decisionCanBacktrack[86]); 6651 6652 int LA86_0 = input.LA(1); 6653 6654 if ( (LA86_0==IDENTIFIER||LA86_0==ABSTRACT||LA86_0==BOOLEAN||LA86_0==BYTE||(LA86_0>=CHAR && LA86_0<=CLASS)||LA86_0==DOUBLE||LA86_0==ENUM||LA86_0==FINAL||LA86_0==FLOAT||(LA86_0>=INT && LA86_0<=NATIVE)||(LA86_0>=PRIVATE && LA86_0<=PUBLIC)||(LA86_0>=SHORT && LA86_0<=STRICTFP)||LA86_0==SYNCHRONIZED||LA86_0==TRANSIENT||(LA86_0>=VOID && LA86_0<=VOLATILE)||LA86_0==SEMI||LA86_0==MONKEYS_AT||LA86_0==LT) ) { 6655 alt86=1; 6656 } 6657 6658 6659 } finally {dbg.exitDecision(86);} 6660 6661 switch (alt86) { 6662 case 1 : 6663 dbg.enterAlt(1); 6664 6665 // src/com/google/doclava/parser/Java.g:767:10: annotationTypeElementDeclaration 6666 { 6667 dbg.location(767,10); 6668 pushFollow(FOLLOW_annotationTypeElementDeclaration_in_annotationTypeBody3739); 6669 annotationTypeElementDeclaration(); 6670 6671 state._fsp--; 6672 if (state.failed) return ; 6673 6674 } 6675 break; 6676 6677 default : 6678 break loop86; 6679 } 6680 } while (true); 6681 } finally {dbg.exitSubRule(86);} 6682 6683 dbg.location(769,9); 6684 match(input,RBRACE,FOLLOW_RBRACE_in_annotationTypeBody3760); if (state.failed) return ; 6685 6686 } 6687 6688 } 6689 catch (RecognitionException re) { 6690 reportError(re); 6691 recover(input,re); 6692 } 6693 finally { 6694 if ( state.backtracking>0 ) { memoize(input, 51, annotationTypeBody_StartIndex); } 6695 } 6696 dbg.location(770, 5); 6697 6698 } 6699 finally { 6700 dbg.exitRule(getGrammarFileName(), "annotationTypeBody"); 6701 decRuleLevel(); 6702 if ( getRuleLevel()==0 ) {dbg.terminate();} 6703 } 6704 6705 return ; 6706 } 6707 // $ANTLR end "annotationTypeBody" 6708 6709 6710 // $ANTLR start "annotationTypeElementDeclaration" 6711 // src/com/google/doclava/parser/Java.g:772:1: annotationTypeElementDeclaration : ( annotationMethodDeclaration | interfaceFieldDeclaration | normalClassDeclaration | normalInterfaceDeclaration | enumDeclaration | annotationTypeDeclaration | ';' ); 6712 public final void annotationTypeElementDeclaration() throws RecognitionException { 6713 int annotationTypeElementDeclaration_StartIndex = input.index(); 6714 try { dbg.enterRule(getGrammarFileName(), "annotationTypeElementDeclaration"); 6715 if ( getRuleLevel()==0 ) {dbg.commence();} 6716 incRuleLevel(); 6717 dbg.location(772, 1); 6718 6719 try { 6720 if ( state.backtracking>0 && alreadyParsedRule(input, 52) ) { return ; } 6721 // src/com/google/doclava/parser/Java.g:776:5: ( annotationMethodDeclaration | interfaceFieldDeclaration | normalClassDeclaration | normalInterfaceDeclaration | enumDeclaration | annotationTypeDeclaration | ';' ) 6722 int alt87=7; 6723 try { dbg.enterDecision(87, decisionCanBacktrack[87]); 6724 6725 try { 6726 isCyclicDecision = true; 6727 alt87 = dfa87.predict(input); 6728 } 6729 catch (NoViableAltException nvae) { 6730 dbg.recognitionException(nvae); 6731 throw nvae; 6732 } 6733 } finally {dbg.exitDecision(87);} 6734 6735 switch (alt87) { 6736 case 1 : 6737 dbg.enterAlt(1); 6738 6739 // src/com/google/doclava/parser/Java.g:776:9: annotationMethodDeclaration 6740 { 6741 dbg.location(776,9); 6742 pushFollow(FOLLOW_annotationMethodDeclaration_in_annotationTypeElementDeclaration3781); 6743 annotationMethodDeclaration(); 6744 6745 state._fsp--; 6746 if (state.failed) return ; 6747 6748 } 6749 break; 6750 case 2 : 6751 dbg.enterAlt(2); 6752 6753 // src/com/google/doclava/parser/Java.g:777:9: interfaceFieldDeclaration 6754 { 6755 dbg.location(777,9); 6756 pushFollow(FOLLOW_interfaceFieldDeclaration_in_annotationTypeElementDeclaration3791); 6757 interfaceFieldDeclaration(); 6758 6759 state._fsp--; 6760 if (state.failed) return ; 6761 6762 } 6763 break; 6764 case 3 : 6765 dbg.enterAlt(3); 6766 6767 // src/com/google/doclava/parser/Java.g:778:9: normalClassDeclaration 6768 { 6769 dbg.location(778,9); 6770 pushFollow(FOLLOW_normalClassDeclaration_in_annotationTypeElementDeclaration3801); 6771 normalClassDeclaration(); 6772 6773 state._fsp--; 6774 if (state.failed) return ; 6775 6776 } 6777 break; 6778 case 4 : 6779 dbg.enterAlt(4); 6780 6781 // src/com/google/doclava/parser/Java.g:779:9: normalInterfaceDeclaration 6782 { 6783 dbg.location(779,9); 6784 pushFollow(FOLLOW_normalInterfaceDeclaration_in_annotationTypeElementDeclaration3811); 6785 normalInterfaceDeclaration(); 6786 6787 state._fsp--; 6788 if (state.failed) return ; 6789 6790 } 6791 break; 6792 case 5 : 6793 dbg.enterAlt(5); 6794 6795 // src/com/google/doclava/parser/Java.g:780:9: enumDeclaration 6796 { 6797 dbg.location(780,9); 6798 pushFollow(FOLLOW_enumDeclaration_in_annotationTypeElementDeclaration3821); 6799 enumDeclaration(); 6800 6801 state._fsp--; 6802 if (state.failed) return ; 6803 6804 } 6805 break; 6806 case 6 : 6807 dbg.enterAlt(6); 6808 6809 // src/com/google/doclava/parser/Java.g:781:9: annotationTypeDeclaration 6810 { 6811 dbg.location(781,9); 6812 pushFollow(FOLLOW_annotationTypeDeclaration_in_annotationTypeElementDeclaration3831); 6813 annotationTypeDeclaration(); 6814 6815 state._fsp--; 6816 if (state.failed) return ; 6817 6818 } 6819 break; 6820 case 7 : 6821 dbg.enterAlt(7); 6822 6823 // src/com/google/doclava/parser/Java.g:782:9: ';' 6824 { 6825 dbg.location(782,9); 6826 match(input,SEMI,FOLLOW_SEMI_in_annotationTypeElementDeclaration3841); if (state.failed) return ; 6827 6828 } 6829 break; 6830 6831 } 6832 } 6833 catch (RecognitionException re) { 6834 reportError(re); 6835 recover(input,re); 6836 } 6837 finally { 6838 if ( state.backtracking>0 ) { memoize(input, 52, annotationTypeElementDeclaration_StartIndex); } 6839 } 6840 dbg.location(783, 5); 6841 6842 } 6843 finally { 6844 dbg.exitRule(getGrammarFileName(), "annotationTypeElementDeclaration"); 6845 decRuleLevel(); 6846 if ( getRuleLevel()==0 ) {dbg.terminate();} 6847 } 6848 6849 return ; 6850 } 6851 // $ANTLR end "annotationTypeElementDeclaration" 6852 6853 6854 // $ANTLR start "annotationMethodDeclaration" 6855 // src/com/google/doclava/parser/Java.g:785:1: annotationMethodDeclaration : modifiers type IDENTIFIER '(' ')' ( 'default' elementValue )? ';' ; 6856 public final void annotationMethodDeclaration() throws RecognitionException { 6857 int annotationMethodDeclaration_StartIndex = input.index(); 6858 try { dbg.enterRule(getGrammarFileName(), "annotationMethodDeclaration"); 6859 if ( getRuleLevel()==0 ) {dbg.commence();} 6860 incRuleLevel(); 6861 dbg.location(785, 1); 6862 6863 try { 6864 if ( state.backtracking>0 && alreadyParsedRule(input, 53) ) { return ; } 6865 // src/com/google/doclava/parser/Java.g:786:5: ( modifiers type IDENTIFIER '(' ')' ( 'default' elementValue )? ';' ) 6866 dbg.enterAlt(1); 6867 6868 // src/com/google/doclava/parser/Java.g:786:9: modifiers type IDENTIFIER '(' ')' ( 'default' elementValue )? ';' 6869 { 6870 dbg.location(786,9); 6871 pushFollow(FOLLOW_modifiers_in_annotationMethodDeclaration3860); 6872 modifiers(); 6873 6874 state._fsp--; 6875 if (state.failed) return ; 6876 dbg.location(786,19); 6877 pushFollow(FOLLOW_type_in_annotationMethodDeclaration3862); 6878 type(); 6879 6880 state._fsp--; 6881 if (state.failed) return ; 6882 dbg.location(786,24); 6883 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_annotationMethodDeclaration3864); if (state.failed) return ; 6884 dbg.location(787,9); 6885 match(input,LPAREN,FOLLOW_LPAREN_in_annotationMethodDeclaration3874); if (state.failed) return ; 6886 dbg.location(787,13); 6887 match(input,RPAREN,FOLLOW_RPAREN_in_annotationMethodDeclaration3876); if (state.failed) return ; 6888 dbg.location(787,17); 6889 // src/com/google/doclava/parser/Java.g:787:17: ( 'default' elementValue )? 6890 int alt88=2; 6891 try { dbg.enterSubRule(88); 6892 try { dbg.enterDecision(88, decisionCanBacktrack[88]); 6893 6894 int LA88_0 = input.LA(1); 6895 6896 if ( (LA88_0==DEFAULT) ) { 6897 alt88=1; 6898 } 6899 } finally {dbg.exitDecision(88);} 6900 6901 switch (alt88) { 6902 case 1 : 6903 dbg.enterAlt(1); 6904 6905 // src/com/google/doclava/parser/Java.g:787:18: 'default' elementValue 6906 { 6907 dbg.location(787,18); 6908 match(input,DEFAULT,FOLLOW_DEFAULT_in_annotationMethodDeclaration3879); if (state.failed) return ; 6909 dbg.location(787,28); 6910 pushFollow(FOLLOW_elementValue_in_annotationMethodDeclaration3881); 6911 elementValue(); 6912 6913 state._fsp--; 6914 if (state.failed) return ; 6915 6916 } 6917 break; 6918 6919 } 6920 } finally {dbg.exitSubRule(88);} 6921 6922 dbg.location(789,9); 6923 match(input,SEMI,FOLLOW_SEMI_in_annotationMethodDeclaration3910); if (state.failed) return ; 6924 6925 } 6926 6927 } 6928 catch (RecognitionException re) { 6929 reportError(re); 6930 recover(input,re); 6931 } 6932 finally { 6933 if ( state.backtracking>0 ) { memoize(input, 53, annotationMethodDeclaration_StartIndex); } 6934 } 6935 dbg.location(790, 9); 6936 6937 } 6938 finally { 6939 dbg.exitRule(getGrammarFileName(), "annotationMethodDeclaration"); 6940 decRuleLevel(); 6941 if ( getRuleLevel()==0 ) {dbg.terminate();} 6942 } 6943 6944 return ; 6945 } 6946 // $ANTLR end "annotationMethodDeclaration" 6947 6948 6949 // $ANTLR start "block" 6950 // src/com/google/doclava/parser/Java.g:792:1: block : '{' ( blockStatement )* '}' ; 6951 public final void block() throws RecognitionException { 6952 int block_StartIndex = input.index(); 6953 try { dbg.enterRule(getGrammarFileName(), "block"); 6954 if ( getRuleLevel()==0 ) {dbg.commence();} 6955 incRuleLevel(); 6956 dbg.location(792, 1); 6957 6958 try { 6959 if ( state.backtracking>0 && alreadyParsedRule(input, 54) ) { return ; } 6960 // src/com/google/doclava/parser/Java.g:793:5: ( '{' ( blockStatement )* '}' ) 6961 dbg.enterAlt(1); 6962 6963 // src/com/google/doclava/parser/Java.g:793:9: '{' ( blockStatement )* '}' 6964 { 6965 dbg.location(793,9); 6966 match(input,LBRACE,FOLLOW_LBRACE_in_block3933); if (state.failed) return ; 6967 dbg.location(794,9); 6968 // src/com/google/doclava/parser/Java.g:794:9: ( blockStatement )* 6969 try { dbg.enterSubRule(89); 6970 6971 loop89: 6972 do { 6973 int alt89=2; 6974 try { dbg.enterDecision(89, decisionCanBacktrack[89]); 6975 6976 int LA89_0 = input.LA(1); 6977 6978 if ( ((LA89_0>=IDENTIFIER && LA89_0<=NULL)||(LA89_0>=ABSTRACT && LA89_0<=BYTE)||(LA89_0>=CHAR && LA89_0<=CLASS)||LA89_0==CONTINUE||(LA89_0>=DO && LA89_0<=DOUBLE)||LA89_0==ENUM||LA89_0==FINAL||(LA89_0>=FLOAT && LA89_0<=FOR)||LA89_0==IF||(LA89_0>=INT && LA89_0<=NEW)||(LA89_0>=PRIVATE && LA89_0<=THROW)||(LA89_0>=TRANSIENT && LA89_0<=LPAREN)||LA89_0==LBRACE||LA89_0==SEMI||(LA89_0>=BANG && LA89_0<=TILDE)||(LA89_0>=PLUSPLUS && LA89_0<=SUB)||LA89_0==MONKEYS_AT||LA89_0==LT) ) { 6979 alt89=1; 6980 } 6981 6982 6983 } finally {dbg.exitDecision(89);} 6984 6985 switch (alt89) { 6986 case 1 : 6987 dbg.enterAlt(1); 6988 6989 // src/com/google/doclava/parser/Java.g:794:10: blockStatement 6990 { 6991 dbg.location(794,10); 6992 pushFollow(FOLLOW_blockStatement_in_block3944); 6993 blockStatement(); 6994 6995 state._fsp--; 6996 if (state.failed) return ; 6997 6998 } 6999 break; 7000 7001 default : 7002 break loop89; 7003 } 7004 } while (true); 7005 } finally {dbg.exitSubRule(89);} 7006 7007 dbg.location(796,9); 7008 match(input,RBRACE,FOLLOW_RBRACE_in_block3965); if (state.failed) return ; 7009 7010 } 7011 7012 } 7013 catch (RecognitionException re) { 7014 reportError(re); 7015 recover(input,re); 7016 } 7017 finally { 7018 if ( state.backtracking>0 ) { memoize(input, 54, block_StartIndex); } 7019 } 7020 dbg.location(797, 5); 7021 7022 } 7023 finally { 7024 dbg.exitRule(getGrammarFileName(), "block"); 7025 decRuleLevel(); 7026 if ( getRuleLevel()==0 ) {dbg.terminate();} 7027 } 7028 7029 return ; 7030 } 7031 // $ANTLR end "block" 7032 7033 7034 // $ANTLR start "blockStatement" 7035 // src/com/google/doclava/parser/Java.g:823:1: blockStatement : ( localVariableDeclarationStatement | classOrInterfaceDeclaration | statement ); 7036 public final void blockStatement() throws RecognitionException { 7037 int blockStatement_StartIndex = input.index(); 7038 try { dbg.enterRule(getGrammarFileName(), "blockStatement"); 7039 if ( getRuleLevel()==0 ) {dbg.commence();} 7040 incRuleLevel(); 7041 dbg.location(823, 1); 7042 7043 try { 7044 if ( state.backtracking>0 && alreadyParsedRule(input, 55) ) { return ; } 7045 // src/com/google/doclava/parser/Java.g:824:5: ( localVariableDeclarationStatement | classOrInterfaceDeclaration | statement ) 7046 int alt90=3; 7047 try { dbg.enterDecision(90, decisionCanBacktrack[90]); 7048 7049 try { 7050 isCyclicDecision = true; 7051 alt90 = dfa90.predict(input); 7052 } 7053 catch (NoViableAltException nvae) { 7054 dbg.recognitionException(nvae); 7055 throw nvae; 7056 } 7057 } finally {dbg.exitDecision(90);} 7058 7059 switch (alt90) { 7060 case 1 : 7061 dbg.enterAlt(1); 7062 7063 // src/com/google/doclava/parser/Java.g:824:9: localVariableDeclarationStatement 7064 { 7065 dbg.location(824,9); 7066 pushFollow(FOLLOW_localVariableDeclarationStatement_in_blockStatement3986); 7067 localVariableDeclarationStatement(); 7068 7069 state._fsp--; 7070 if (state.failed) return ; 7071 7072 } 7073 break; 7074 case 2 : 7075 dbg.enterAlt(2); 7076 7077 // src/com/google/doclava/parser/Java.g:825:9: classOrInterfaceDeclaration 7078 { 7079 dbg.location(825,9); 7080 pushFollow(FOLLOW_classOrInterfaceDeclaration_in_blockStatement3996); 7081 classOrInterfaceDeclaration(); 7082 7083 state._fsp--; 7084 if (state.failed) return ; 7085 7086 } 7087 break; 7088 case 3 : 7089 dbg.enterAlt(3); 7090 7091 // src/com/google/doclava/parser/Java.g:826:9: statement 7092 { 7093 dbg.location(826,9); 7094 pushFollow(FOLLOW_statement_in_blockStatement4006); 7095 statement(); 7096 7097 state._fsp--; 7098 if (state.failed) return ; 7099 7100 } 7101 break; 7102 7103 } 7104 } 7105 catch (RecognitionException re) { 7106 reportError(re); 7107 recover(input,re); 7108 } 7109 finally { 7110 if ( state.backtracking>0 ) { memoize(input, 55, blockStatement_StartIndex); } 7111 } 7112 dbg.location(827, 5); 7113 7114 } 7115 finally { 7116 dbg.exitRule(getGrammarFileName(), "blockStatement"); 7117 decRuleLevel(); 7118 if ( getRuleLevel()==0 ) {dbg.terminate();} 7119 } 7120 7121 return ; 7122 } 7123 // $ANTLR end "blockStatement" 7124 7125 7126 // $ANTLR start "localVariableDeclarationStatement" 7127 // src/com/google/doclava/parser/Java.g:830:1: localVariableDeclarationStatement : localVariableDeclaration ';' ; 7128 public final void localVariableDeclarationStatement() throws RecognitionException { 7129 int localVariableDeclarationStatement_StartIndex = input.index(); 7130 try { dbg.enterRule(getGrammarFileName(), "localVariableDeclarationStatement"); 7131 if ( getRuleLevel()==0 ) {dbg.commence();} 7132 incRuleLevel(); 7133 dbg.location(830, 1); 7134 7135 try { 7136 if ( state.backtracking>0 && alreadyParsedRule(input, 56) ) { return ; } 7137 // src/com/google/doclava/parser/Java.g:831:5: ( localVariableDeclaration ';' ) 7138 dbg.enterAlt(1); 7139 7140 // src/com/google/doclava/parser/Java.g:831:9: localVariableDeclaration ';' 7141 { 7142 dbg.location(831,9); 7143 pushFollow(FOLLOW_localVariableDeclaration_in_localVariableDeclarationStatement4026); 7144 localVariableDeclaration(); 7145 7146 state._fsp--; 7147 if (state.failed) return ; 7148 dbg.location(832,9); 7149 match(input,SEMI,FOLLOW_SEMI_in_localVariableDeclarationStatement4036); if (state.failed) return ; 7150 7151 } 7152 7153 } 7154 catch (RecognitionException re) { 7155 reportError(re); 7156 recover(input,re); 7157 } 7158 finally { 7159 if ( state.backtracking>0 ) { memoize(input, 56, localVariableDeclarationStatement_StartIndex); } 7160 } 7161 dbg.location(833, 5); 7162 7163 } 7164 finally { 7165 dbg.exitRule(getGrammarFileName(), "localVariableDeclarationStatement"); 7166 decRuleLevel(); 7167 if ( getRuleLevel()==0 ) {dbg.terminate();} 7168 } 7169 7170 return ; 7171 } 7172 // $ANTLR end "localVariableDeclarationStatement" 7173 7174 7175 // $ANTLR start "localVariableDeclaration" 7176 // src/com/google/doclava/parser/Java.g:835:1: localVariableDeclaration : variableModifiers type variableDeclarator ( ',' variableDeclarator )* ; 7177 public final void localVariableDeclaration() throws RecognitionException { 7178 int localVariableDeclaration_StartIndex = input.index(); 7179 try { dbg.enterRule(getGrammarFileName(), "localVariableDeclaration"); 7180 if ( getRuleLevel()==0 ) {dbg.commence();} 7181 incRuleLevel(); 7182 dbg.location(835, 1); 7183 7184 try { 7185 if ( state.backtracking>0 && alreadyParsedRule(input, 57) ) { return ; } 7186 // src/com/google/doclava/parser/Java.g:836:5: ( variableModifiers type variableDeclarator ( ',' variableDeclarator )* ) 7187 dbg.enterAlt(1); 7188 7189 // src/com/google/doclava/parser/Java.g:836:9: variableModifiers type variableDeclarator ( ',' variableDeclarator )* 7190 { 7191 dbg.location(836,9); 7192 pushFollow(FOLLOW_variableModifiers_in_localVariableDeclaration4055); 7193 variableModifiers(); 7194 7195 state._fsp--; 7196 if (state.failed) return ; 7197 dbg.location(836,27); 7198 pushFollow(FOLLOW_type_in_localVariableDeclaration4057); 7199 type(); 7200 7201 state._fsp--; 7202 if (state.failed) return ; 7203 dbg.location(837,9); 7204 pushFollow(FOLLOW_variableDeclarator_in_localVariableDeclaration4067); 7205 variableDeclarator(); 7206 7207 state._fsp--; 7208 if (state.failed) return ; 7209 dbg.location(838,9); 7210 // src/com/google/doclava/parser/Java.g:838:9: ( ',' variableDeclarator )* 7211 try { dbg.enterSubRule(91); 7212 7213 loop91: 7214 do { 7215 int alt91=2; 7216 try { dbg.enterDecision(91, decisionCanBacktrack[91]); 7217 7218 int LA91_0 = input.LA(1); 7219 7220 if ( (LA91_0==COMMA) ) { 7221 alt91=1; 7222 } 7223 7224 7225 } finally {dbg.exitDecision(91);} 7226 7227 switch (alt91) { 7228 case 1 : 7229 dbg.enterAlt(1); 7230 7231 // src/com/google/doclava/parser/Java.g:838:10: ',' variableDeclarator 7232 { 7233 dbg.location(838,10); 7234 match(input,COMMA,FOLLOW_COMMA_in_localVariableDeclaration4078); if (state.failed) return ; 7235 dbg.location(838,14); 7236 pushFollow(FOLLOW_variableDeclarator_in_localVariableDeclaration4080); 7237 variableDeclarator(); 7238 7239 state._fsp--; 7240 if (state.failed) return ; 7241 7242 } 7243 break; 7244 7245 default : 7246 break loop91; 7247 } 7248 } while (true); 7249 } finally {dbg.exitSubRule(91);} 7250 7251 7252 } 7253 7254 } 7255 catch (RecognitionException re) { 7256 reportError(re); 7257 recover(input,re); 7258 } 7259 finally { 7260 if ( state.backtracking>0 ) { memoize(input, 57, localVariableDeclaration_StartIndex); } 7261 } 7262 dbg.location(840, 5); 7263 7264 } 7265 finally { 7266 dbg.exitRule(getGrammarFileName(), "localVariableDeclaration"); 7267 decRuleLevel(); 7268 if ( getRuleLevel()==0 ) {dbg.terminate();} 7269 } 7270 7271 return ; 7272 } 7273 // $ANTLR end "localVariableDeclaration" 7274 7275 7276 // $ANTLR start "statement" 7277 // src/com/google/doclava/parser/Java.g:842:1: statement : ( block | ( 'assert' ) expression ( ':' expression )? ';' | 'assert' expression ( ':' expression )? ';' | 'if' parExpression statement ( 'else' statement )? | forstatement | 'while' parExpression statement | 'do' statement 'while' parExpression ';' | trystatement | 'switch' parExpression '{' switchBlockStatementGroups '}' | 'synchronized' parExpression block | 'return' ( expression )? ';' | 'throw' expression ';' | 'break' ( IDENTIFIER )? ';' | 'continue' ( IDENTIFIER )? ';' | expression ';' | IDENTIFIER ':' statement | ';' ); 7278 public final void statement() throws RecognitionException { 7279 int statement_StartIndex = input.index(); 7280 try { dbg.enterRule(getGrammarFileName(), "statement"); 7281 if ( getRuleLevel()==0 ) {dbg.commence();} 7282 incRuleLevel(); 7283 dbg.location(842, 1); 7284 7285 try { 7286 if ( state.backtracking>0 && alreadyParsedRule(input, 58) ) { return ; } 7287 // src/com/google/doclava/parser/Java.g:843:5: ( block | ( 'assert' ) expression ( ':' expression )? ';' | 'assert' expression ( ':' expression )? ';' | 'if' parExpression statement ( 'else' statement )? | forstatement | 'while' parExpression statement | 'do' statement 'while' parExpression ';' | trystatement | 'switch' parExpression '{' switchBlockStatementGroups '}' | 'synchronized' parExpression block | 'return' ( expression )? ';' | 'throw' expression ';' | 'break' ( IDENTIFIER )? ';' | 'continue' ( IDENTIFIER )? ';' | expression ';' | IDENTIFIER ':' statement | ';' ) 7288 int alt98=17; 7289 try { dbg.enterDecision(98, decisionCanBacktrack[98]); 7290 7291 try { 7292 isCyclicDecision = true; 7293 alt98 = dfa98.predict(input); 7294 } 7295 catch (NoViableAltException nvae) { 7296 dbg.recognitionException(nvae); 7297 throw nvae; 7298 } 7299 } finally {dbg.exitDecision(98);} 7300 7301 switch (alt98) { 7302 case 1 : 7303 dbg.enterAlt(1); 7304 7305 // src/com/google/doclava/parser/Java.g:843:9: block 7306 { 7307 dbg.location(843,9); 7308 pushFollow(FOLLOW_block_in_statement4110); 7309 block(); 7310 7311 state._fsp--; 7312 if (state.failed) return ; 7313 7314 } 7315 break; 7316 case 2 : 7317 dbg.enterAlt(2); 7318 7319 // src/com/google/doclava/parser/Java.g:845:9: ( 'assert' ) expression ( ':' expression )? ';' 7320 { 7321 dbg.location(845,9); 7322 // src/com/google/doclava/parser/Java.g:845:9: ( 'assert' ) 7323 dbg.enterAlt(1); 7324 7325 // src/com/google/doclava/parser/Java.g:845:10: 'assert' 7326 { 7327 dbg.location(845,10); 7328 match(input,ASSERT,FOLLOW_ASSERT_in_statement4122); if (state.failed) return ; 7329 7330 } 7331 7332 dbg.location(847,9); 7333 pushFollow(FOLLOW_expression_in_statement4142); 7334 expression(); 7335 7336 state._fsp--; 7337 if (state.failed) return ; 7338 dbg.location(847,20); 7339 // src/com/google/doclava/parser/Java.g:847:20: ( ':' expression )? 7340 int alt92=2; 7341 try { dbg.enterSubRule(92); 7342 try { dbg.enterDecision(92, decisionCanBacktrack[92]); 7343 7344 int LA92_0 = input.LA(1); 7345 7346 if ( (LA92_0==COLON) ) { 7347 alt92=1; 7348 } 7349 } finally {dbg.exitDecision(92);} 7350 7351 switch (alt92) { 7352 case 1 : 7353 dbg.enterAlt(1); 7354 7355 // src/com/google/doclava/parser/Java.g:847:21: ':' expression 7356 { 7357 dbg.location(847,21); 7358 match(input,COLON,FOLLOW_COLON_in_statement4145); if (state.failed) return ; 7359 dbg.location(847,25); 7360 pushFollow(FOLLOW_expression_in_statement4147); 7361 expression(); 7362 7363 state._fsp--; 7364 if (state.failed) return ; 7365 7366 } 7367 break; 7368 7369 } 7370 } finally {dbg.exitSubRule(92);} 7371 7372 dbg.location(847,38); 7373 match(input,SEMI,FOLLOW_SEMI_in_statement4151); if (state.failed) return ; 7374 7375 } 7376 break; 7377 case 3 : 7378 dbg.enterAlt(3); 7379 7380 // src/com/google/doclava/parser/Java.g:848:9: 'assert' expression ( ':' expression )? ';' 7381 { 7382 dbg.location(848,9); 7383 match(input,ASSERT,FOLLOW_ASSERT_in_statement4161); if (state.failed) return ; 7384 dbg.location(848,19); 7385 pushFollow(FOLLOW_expression_in_statement4164); 7386 expression(); 7387 7388 state._fsp--; 7389 if (state.failed) return ; 7390 dbg.location(848,30); 7391 // src/com/google/doclava/parser/Java.g:848:30: ( ':' expression )? 7392 int alt93=2; 7393 try { dbg.enterSubRule(93); 7394 try { dbg.enterDecision(93, decisionCanBacktrack[93]); 7395 7396 int LA93_0 = input.LA(1); 7397 7398 if ( (LA93_0==COLON) ) { 7399 alt93=1; 7400 } 7401 } finally {dbg.exitDecision(93);} 7402 7403 switch (alt93) { 7404 case 1 : 7405 dbg.enterAlt(1); 7406 7407 // src/com/google/doclava/parser/Java.g:848:31: ':' expression 7408 { 7409 dbg.location(848,31); 7410 match(input,COLON,FOLLOW_COLON_in_statement4167); if (state.failed) return ; 7411 dbg.location(848,35); 7412 pushFollow(FOLLOW_expression_in_statement4169); 7413 expression(); 7414 7415 state._fsp--; 7416 if (state.failed) return ; 7417 7418 } 7419 break; 7420 7421 } 7422 } finally {dbg.exitSubRule(93);} 7423 7424 dbg.location(848,48); 7425 match(input,SEMI,FOLLOW_SEMI_in_statement4173); if (state.failed) return ; 7426 7427 } 7428 break; 7429 case 4 : 7430 dbg.enterAlt(4); 7431 7432 // src/com/google/doclava/parser/Java.g:849:9: 'if' parExpression statement ( 'else' statement )? 7433 { 7434 dbg.location(849,9); 7435 match(input,IF,FOLLOW_IF_in_statement4183); if (state.failed) return ; 7436 dbg.location(849,14); 7437 pushFollow(FOLLOW_parExpression_in_statement4185); 7438 parExpression(); 7439 7440 state._fsp--; 7441 if (state.failed) return ; 7442 dbg.location(849,28); 7443 pushFollow(FOLLOW_statement_in_statement4187); 7444 statement(); 7445 7446 state._fsp--; 7447 if (state.failed) return ; 7448 dbg.location(849,38); 7449 // src/com/google/doclava/parser/Java.g:849:38: ( 'else' statement )? 7450 int alt94=2; 7451 try { dbg.enterSubRule(94); 7452 try { dbg.enterDecision(94, decisionCanBacktrack[94]); 7453 7454 int LA94_0 = input.LA(1); 7455 7456 if ( (LA94_0==ELSE) ) { 7457 int LA94_1 = input.LA(2); 7458 7459 if ( (synpred133_Java()) ) { 7460 alt94=1; 7461 } 7462 } 7463 } finally {dbg.exitDecision(94);} 7464 7465 switch (alt94) { 7466 case 1 : 7467 dbg.enterAlt(1); 7468 7469 // src/com/google/doclava/parser/Java.g:849:39: 'else' statement 7470 { 7471 dbg.location(849,39); 7472 match(input,ELSE,FOLLOW_ELSE_in_statement4190); if (state.failed) return ; 7473 dbg.location(849,46); 7474 pushFollow(FOLLOW_statement_in_statement4192); 7475 statement(); 7476 7477 state._fsp--; 7478 if (state.failed) return ; 7479 7480 } 7481 break; 7482 7483 } 7484 } finally {dbg.exitSubRule(94);} 7485 7486 7487 } 7488 break; 7489 case 5 : 7490 dbg.enterAlt(5); 7491 7492 // src/com/google/doclava/parser/Java.g:850:9: forstatement 7493 { 7494 dbg.location(850,9); 7495 pushFollow(FOLLOW_forstatement_in_statement4204); 7496 forstatement(); 7497 7498 state._fsp--; 7499 if (state.failed) return ; 7500 7501 } 7502 break; 7503 case 6 : 7504 dbg.enterAlt(6); 7505 7506 // src/com/google/doclava/parser/Java.g:851:9: 'while' parExpression statement 7507 { 7508 dbg.location(851,9); 7509 match(input,WHILE,FOLLOW_WHILE_in_statement4214); if (state.failed) return ; 7510 dbg.location(851,17); 7511 pushFollow(FOLLOW_parExpression_in_statement4216); 7512 parExpression(); 7513 7514 state._fsp--; 7515 if (state.failed) return ; 7516 dbg.location(851,31); 7517 pushFollow(FOLLOW_statement_in_statement4218); 7518 statement(); 7519 7520 state._fsp--; 7521 if (state.failed) return ; 7522 7523 } 7524 break; 7525 case 7 : 7526 dbg.enterAlt(7); 7527 7528 // src/com/google/doclava/parser/Java.g:852:9: 'do' statement 'while' parExpression ';' 7529 { 7530 dbg.location(852,9); 7531 match(input,DO,FOLLOW_DO_in_statement4228); if (state.failed) return ; 7532 dbg.location(852,14); 7533 pushFollow(FOLLOW_statement_in_statement4230); 7534 statement(); 7535 7536 state._fsp--; 7537 if (state.failed) return ; 7538 dbg.location(852,24); 7539 match(input,WHILE,FOLLOW_WHILE_in_statement4232); if (state.failed) return ; 7540 dbg.location(852,32); 7541 pushFollow(FOLLOW_parExpression_in_statement4234); 7542 parExpression(); 7543 7544 state._fsp--; 7545 if (state.failed) return ; 7546 dbg.location(852,46); 7547 match(input,SEMI,FOLLOW_SEMI_in_statement4236); if (state.failed) return ; 7548 7549 } 7550 break; 7551 case 8 : 7552 dbg.enterAlt(8); 7553 7554 // src/com/google/doclava/parser/Java.g:853:9: trystatement 7555 { 7556 dbg.location(853,9); 7557 pushFollow(FOLLOW_trystatement_in_statement4246); 7558 trystatement(); 7559 7560 state._fsp--; 7561 if (state.failed) return ; 7562 7563 } 7564 break; 7565 case 9 : 7566 dbg.enterAlt(9); 7567 7568 // src/com/google/doclava/parser/Java.g:854:9: 'switch' parExpression '{' switchBlockStatementGroups '}' 7569 { 7570 dbg.location(854,9); 7571 match(input,SWITCH,FOLLOW_SWITCH_in_statement4256); if (state.failed) return ; 7572 dbg.location(854,18); 7573 pushFollow(FOLLOW_parExpression_in_statement4258); 7574 parExpression(); 7575 7576 state._fsp--; 7577 if (state.failed) return ; 7578 dbg.location(854,32); 7579 match(input,LBRACE,FOLLOW_LBRACE_in_statement4260); if (state.failed) return ; 7580 dbg.location(854,36); 7581 pushFollow(FOLLOW_switchBlockStatementGroups_in_statement4262); 7582 switchBlockStatementGroups(); 7583 7584 state._fsp--; 7585 if (state.failed) return ; 7586 dbg.location(854,63); 7587 match(input,RBRACE,FOLLOW_RBRACE_in_statement4264); if (state.failed) return ; 7588 7589 } 7590 break; 7591 case 10 : 7592 dbg.enterAlt(10); 7593 7594 // src/com/google/doclava/parser/Java.g:855:9: 'synchronized' parExpression block 7595 { 7596 dbg.location(855,9); 7597 match(input,SYNCHRONIZED,FOLLOW_SYNCHRONIZED_in_statement4274); if (state.failed) return ; 7598 dbg.location(855,24); 7599 pushFollow(FOLLOW_parExpression_in_statement4276); 7600 parExpression(); 7601 7602 state._fsp--; 7603 if (state.failed) return ; 7604 dbg.location(855,38); 7605 pushFollow(FOLLOW_block_in_statement4278); 7606 block(); 7607 7608 state._fsp--; 7609 if (state.failed) return ; 7610 7611 } 7612 break; 7613 case 11 : 7614 dbg.enterAlt(11); 7615 7616 // src/com/google/doclava/parser/Java.g:856:9: 'return' ( expression )? ';' 7617 { 7618 dbg.location(856,9); 7619 match(input,RETURN,FOLLOW_RETURN_in_statement4288); if (state.failed) return ; 7620 dbg.location(856,18); 7621 // src/com/google/doclava/parser/Java.g:856:18: ( expression )? 7622 int alt95=2; 7623 try { dbg.enterSubRule(95); 7624 try { dbg.enterDecision(95, decisionCanBacktrack[95]); 7625 7626 int LA95_0 = input.LA(1); 7627 7628 if ( ((LA95_0>=IDENTIFIER && LA95_0<=NULL)||LA95_0==BOOLEAN||LA95_0==BYTE||LA95_0==CHAR||LA95_0==DOUBLE||LA95_0==FLOAT||LA95_0==INT||LA95_0==LONG||LA95_0==NEW||LA95_0==SHORT||LA95_0==SUPER||LA95_0==THIS||LA95_0==VOID||LA95_0==LPAREN||(LA95_0>=BANG && LA95_0<=TILDE)||(LA95_0>=PLUSPLUS && LA95_0<=SUB)) ) { 7629 alt95=1; 7630 } 7631 } finally {dbg.exitDecision(95);} 7632 7633 switch (alt95) { 7634 case 1 : 7635 dbg.enterAlt(1); 7636 7637 // src/com/google/doclava/parser/Java.g:856:19: expression 7638 { 7639 dbg.location(856,19); 7640 pushFollow(FOLLOW_expression_in_statement4291); 7641 expression(); 7642 7643 state._fsp--; 7644 if (state.failed) return ; 7645 7646 } 7647 break; 7648 7649 } 7650 } finally {dbg.exitSubRule(95);} 7651 7652 dbg.location(856,33); 7653 match(input,SEMI,FOLLOW_SEMI_in_statement4296); if (state.failed) return ; 7654 7655 } 7656 break; 7657 case 12 : 7658 dbg.enterAlt(12); 7659 7660 // src/com/google/doclava/parser/Java.g:857:9: 'throw' expression ';' 7661 { 7662 dbg.location(857,9); 7663 match(input,THROW,FOLLOW_THROW_in_statement4306); if (state.failed) return ; 7664 dbg.location(857,17); 7665 pushFollow(FOLLOW_expression_in_statement4308); 7666 expression(); 7667 7668 state._fsp--; 7669 if (state.failed) return ; 7670 dbg.location(857,28); 7671 match(input,SEMI,FOLLOW_SEMI_in_statement4310); if (state.failed) return ; 7672 7673 } 7674 break; 7675 case 13 : 7676 dbg.enterAlt(13); 7677 7678 // src/com/google/doclava/parser/Java.g:858:9: 'break' ( IDENTIFIER )? ';' 7679 { 7680 dbg.location(858,9); 7681 match(input,BREAK,FOLLOW_BREAK_in_statement4320); if (state.failed) return ; 7682 dbg.location(859,13); 7683 // src/com/google/doclava/parser/Java.g:859:13: ( IDENTIFIER )? 7684 int alt96=2; 7685 try { dbg.enterSubRule(96); 7686 try { dbg.enterDecision(96, decisionCanBacktrack[96]); 7687 7688 int LA96_0 = input.LA(1); 7689 7690 if ( (LA96_0==IDENTIFIER) ) { 7691 alt96=1; 7692 } 7693 } finally {dbg.exitDecision(96);} 7694 7695 switch (alt96) { 7696 case 1 : 7697 dbg.enterAlt(1); 7698 7699 // src/com/google/doclava/parser/Java.g:859:14: IDENTIFIER 7700 { 7701 dbg.location(859,14); 7702 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_statement4335); if (state.failed) return ; 7703 7704 } 7705 break; 7706 7707 } 7708 } finally {dbg.exitSubRule(96);} 7709 7710 dbg.location(860,16); 7711 match(input,SEMI,FOLLOW_SEMI_in_statement4352); if (state.failed) return ; 7712 7713 } 7714 break; 7715 case 14 : 7716 dbg.enterAlt(14); 7717 7718 // src/com/google/doclava/parser/Java.g:861:9: 'continue' ( IDENTIFIER )? ';' 7719 { 7720 dbg.location(861,9); 7721 match(input,CONTINUE,FOLLOW_CONTINUE_in_statement4362); if (state.failed) return ; 7722 dbg.location(862,13); 7723 // src/com/google/doclava/parser/Java.g:862:13: ( IDENTIFIER )? 7724 int alt97=2; 7725 try { dbg.enterSubRule(97); 7726 try { dbg.enterDecision(97, decisionCanBacktrack[97]); 7727 7728 int LA97_0 = input.LA(1); 7729 7730 if ( (LA97_0==IDENTIFIER) ) { 7731 alt97=1; 7732 } 7733 } finally {dbg.exitDecision(97);} 7734 7735 switch (alt97) { 7736 case 1 : 7737 dbg.enterAlt(1); 7738 7739 // src/com/google/doclava/parser/Java.g:862:14: IDENTIFIER 7740 { 7741 dbg.location(862,14); 7742 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_statement4377); if (state.failed) return ; 7743 7744 } 7745 break; 7746 7747 } 7748 } finally {dbg.exitSubRule(97);} 7749 7750 dbg.location(863,16); 7751 match(input,SEMI,FOLLOW_SEMI_in_statement4394); if (state.failed) return ; 7752 7753 } 7754 break; 7755 case 15 : 7756 dbg.enterAlt(15); 7757 7758 // src/com/google/doclava/parser/Java.g:864:9: expression ';' 7759 { 7760 dbg.location(864,9); 7761 pushFollow(FOLLOW_expression_in_statement4404); 7762 expression(); 7763 7764 state._fsp--; 7765 if (state.failed) return ; 7766 dbg.location(864,21); 7767 match(input,SEMI,FOLLOW_SEMI_in_statement4407); if (state.failed) return ; 7768 7769 } 7770 break; 7771 case 16 : 7772 dbg.enterAlt(16); 7773 7774 // src/com/google/doclava/parser/Java.g:865:9: IDENTIFIER ':' statement 7775 { 7776 dbg.location(865,9); 7777 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_statement4417); if (state.failed) return ; 7778 dbg.location(865,20); 7779 match(input,COLON,FOLLOW_COLON_in_statement4419); if (state.failed) return ; 7780 dbg.location(865,24); 7781 pushFollow(FOLLOW_statement_in_statement4421); 7782 statement(); 7783 7784 state._fsp--; 7785 if (state.failed) return ; 7786 7787 } 7788 break; 7789 case 17 : 7790 dbg.enterAlt(17); 7791 7792 // src/com/google/doclava/parser/Java.g:866:9: ';' 7793 { 7794 dbg.location(866,9); 7795 match(input,SEMI,FOLLOW_SEMI_in_statement4431); if (state.failed) return ; 7796 7797 } 7798 break; 7799 7800 } 7801 } 7802 catch (RecognitionException re) { 7803 reportError(re); 7804 recover(input,re); 7805 } 7806 finally { 7807 if ( state.backtracking>0 ) { memoize(input, 58, statement_StartIndex); } 7808 } 7809 dbg.location(868, 5); 7810 7811 } 7812 finally { 7813 dbg.exitRule(getGrammarFileName(), "statement"); 7814 decRuleLevel(); 7815 if ( getRuleLevel()==0 ) {dbg.terminate();} 7816 } 7817 7818 return ; 7819 } 7820 // $ANTLR end "statement" 7821 7822 7823 // $ANTLR start "switchBlockStatementGroups" 7824 // src/com/google/doclava/parser/Java.g:870:1: switchBlockStatementGroups : ( switchBlockStatementGroup )* ; 7825 public final void switchBlockStatementGroups() throws RecognitionException { 7826 int switchBlockStatementGroups_StartIndex = input.index(); 7827 try { dbg.enterRule(getGrammarFileName(), "switchBlockStatementGroups"); 7828 if ( getRuleLevel()==0 ) {dbg.commence();} 7829 incRuleLevel(); 7830 dbg.location(870, 1); 7831 7832 try { 7833 if ( state.backtracking>0 && alreadyParsedRule(input, 59) ) { return ; } 7834 // src/com/google/doclava/parser/Java.g:871:5: ( ( switchBlockStatementGroup )* ) 7835 dbg.enterAlt(1); 7836 7837 // src/com/google/doclava/parser/Java.g:871:9: ( switchBlockStatementGroup )* 7838 { 7839 dbg.location(871,9); 7840 // src/com/google/doclava/parser/Java.g:871:9: ( switchBlockStatementGroup )* 7841 try { dbg.enterSubRule(99); 7842 7843 loop99: 7844 do { 7845 int alt99=2; 7846 try { dbg.enterDecision(99, decisionCanBacktrack[99]); 7847 7848 int LA99_0 = input.LA(1); 7849 7850 if ( (LA99_0==CASE||LA99_0==DEFAULT) ) { 7851 alt99=1; 7852 } 7853 7854 7855 } finally {dbg.exitDecision(99);} 7856 7857 switch (alt99) { 7858 case 1 : 7859 dbg.enterAlt(1); 7860 7861 // src/com/google/doclava/parser/Java.g:871:10: switchBlockStatementGroup 7862 { 7863 dbg.location(871,10); 7864 pushFollow(FOLLOW_switchBlockStatementGroup_in_switchBlockStatementGroups4452); 7865 switchBlockStatementGroup(); 7866 7867 state._fsp--; 7868 if (state.failed) return ; 7869 7870 } 7871 break; 7872 7873 default : 7874 break loop99; 7875 } 7876 } while (true); 7877 } finally {dbg.exitSubRule(99);} 7878 7879 7880 } 7881 7882 } 7883 catch (RecognitionException re) { 7884 reportError(re); 7885 recover(input,re); 7886 } 7887 finally { 7888 if ( state.backtracking>0 ) { memoize(input, 59, switchBlockStatementGroups_StartIndex); } 7889 } 7890 dbg.location(872, 5); 7891 7892 } 7893 finally { 7894 dbg.exitRule(getGrammarFileName(), "switchBlockStatementGroups"); 7895 decRuleLevel(); 7896 if ( getRuleLevel()==0 ) {dbg.terminate();} 7897 } 7898 7899 return ; 7900 } 7901 // $ANTLR end "switchBlockStatementGroups" 7902 7903 7904 // $ANTLR start "switchBlockStatementGroup" 7905 // src/com/google/doclava/parser/Java.g:874:1: switchBlockStatementGroup : switchLabel ( blockStatement )* ; 7906 public final void switchBlockStatementGroup() throws RecognitionException { 7907 int switchBlockStatementGroup_StartIndex = input.index(); 7908 try { dbg.enterRule(getGrammarFileName(), "switchBlockStatementGroup"); 7909 if ( getRuleLevel()==0 ) {dbg.commence();} 7910 incRuleLevel(); 7911 dbg.location(874, 1); 7912 7913 try { 7914 if ( state.backtracking>0 && alreadyParsedRule(input, 60) ) { return ; } 7915 // src/com/google/doclava/parser/Java.g:875:5: ( switchLabel ( blockStatement )* ) 7916 dbg.enterAlt(1); 7917 7918 // src/com/google/doclava/parser/Java.g:876:9: switchLabel ( blockStatement )* 7919 { 7920 dbg.location(876,9); 7921 pushFollow(FOLLOW_switchLabel_in_switchBlockStatementGroup4480); 7922 switchLabel(); 7923 7924 state._fsp--; 7925 if (state.failed) return ; 7926 dbg.location(877,9); 7927 // src/com/google/doclava/parser/Java.g:877:9: ( blockStatement )* 7928 try { dbg.enterSubRule(100); 7929 7930 loop100: 7931 do { 7932 int alt100=2; 7933 try { dbg.enterDecision(100, decisionCanBacktrack[100]); 7934 7935 int LA100_0 = input.LA(1); 7936 7937 if ( ((LA100_0>=IDENTIFIER && LA100_0<=NULL)||(LA100_0>=ABSTRACT && LA100_0<=BYTE)||(LA100_0>=CHAR && LA100_0<=CLASS)||LA100_0==CONTINUE||(LA100_0>=DO && LA100_0<=DOUBLE)||LA100_0==ENUM||LA100_0==FINAL||(LA100_0>=FLOAT && LA100_0<=FOR)||LA100_0==IF||(LA100_0>=INT && LA100_0<=NEW)||(LA100_0>=PRIVATE && LA100_0<=THROW)||(LA100_0>=TRANSIENT && LA100_0<=LPAREN)||LA100_0==LBRACE||LA100_0==SEMI||(LA100_0>=BANG && LA100_0<=TILDE)||(LA100_0>=PLUSPLUS && LA100_0<=SUB)||LA100_0==MONKEYS_AT||LA100_0==LT) ) { 7938 alt100=1; 7939 } 7940 7941 7942 } finally {dbg.exitDecision(100);} 7943 7944 switch (alt100) { 7945 case 1 : 7946 dbg.enterAlt(1); 7947 7948 // src/com/google/doclava/parser/Java.g:877:10: blockStatement 7949 { 7950 dbg.location(877,10); 7951 pushFollow(FOLLOW_blockStatement_in_switchBlockStatementGroup4491); 7952 blockStatement(); 7953 7954 state._fsp--; 7955 if (state.failed) return ; 7956 7957 } 7958 break; 7959 7960 default : 7961 break loop100; 7962 } 7963 } while (true); 7964 } finally {dbg.exitSubRule(100);} 7965 7966 7967 } 7968 7969 } 7970 catch (RecognitionException re) { 7971 reportError(re); 7972 recover(input,re); 7973 } 7974 finally { 7975 if ( state.backtracking>0 ) { memoize(input, 60, switchBlockStatementGroup_StartIndex); } 7976 } 7977 dbg.location(879, 5); 7978 7979 } 7980 finally { 7981 dbg.exitRule(getGrammarFileName(), "switchBlockStatementGroup"); 7982 decRuleLevel(); 7983 if ( getRuleLevel()==0 ) {dbg.terminate();} 7984 } 7985 7986 return ; 7987 } 7988 // $ANTLR end "switchBlockStatementGroup" 7989 7990 7991 // $ANTLR start "switchLabel" 7992 // src/com/google/doclava/parser/Java.g:881:1: switchLabel : ( 'case' expression ':' | 'default' ':' ); 7993 public final void switchLabel() throws RecognitionException { 7994 int switchLabel_StartIndex = input.index(); 7995 try { dbg.enterRule(getGrammarFileName(), "switchLabel"); 7996 if ( getRuleLevel()==0 ) {dbg.commence();} 7997 incRuleLevel(); 7998 dbg.location(881, 1); 7999 8000 try { 8001 if ( state.backtracking>0 && alreadyParsedRule(input, 61) ) { return ; } 8002 // src/com/google/doclava/parser/Java.g:882:5: ( 'case' expression ':' | 'default' ':' ) 8003 int alt101=2; 8004 try { dbg.enterDecision(101, decisionCanBacktrack[101]); 8005 8006 int LA101_0 = input.LA(1); 8007 8008 if ( (LA101_0==CASE) ) { 8009 alt101=1; 8010 } 8011 else if ( (LA101_0==DEFAULT) ) { 8012 alt101=2; 8013 } 8014 else { 8015 if (state.backtracking>0) {state.failed=true; return ;} 8016 NoViableAltException nvae = 8017 new NoViableAltException("", 101, 0, input); 8018 8019 dbg.recognitionException(nvae); 8020 throw nvae; 8021 } 8022 } finally {dbg.exitDecision(101);} 8023 8024 switch (alt101) { 8025 case 1 : 8026 dbg.enterAlt(1); 8027 8028 // src/com/google/doclava/parser/Java.g:882:9: 'case' expression ':' 8029 { 8030 dbg.location(882,9); 8031 match(input,CASE,FOLLOW_CASE_in_switchLabel4521); if (state.failed) return ; 8032 dbg.location(882,16); 8033 pushFollow(FOLLOW_expression_in_switchLabel4523); 8034 expression(); 8035 8036 state._fsp--; 8037 if (state.failed) return ; 8038 dbg.location(882,27); 8039 match(input,COLON,FOLLOW_COLON_in_switchLabel4525); if (state.failed) return ; 8040 8041 } 8042 break; 8043 case 2 : 8044 dbg.enterAlt(2); 8045 8046 // src/com/google/doclava/parser/Java.g:883:9: 'default' ':' 8047 { 8048 dbg.location(883,9); 8049 match(input,DEFAULT,FOLLOW_DEFAULT_in_switchLabel4535); if (state.failed) return ; 8050 dbg.location(883,19); 8051 match(input,COLON,FOLLOW_COLON_in_switchLabel4537); if (state.failed) return ; 8052 8053 } 8054 break; 8055 8056 } 8057 } 8058 catch (RecognitionException re) { 8059 reportError(re); 8060 recover(input,re); 8061 } 8062 finally { 8063 if ( state.backtracking>0 ) { memoize(input, 61, switchLabel_StartIndex); } 8064 } 8065 dbg.location(884, 5); 8066 8067 } 8068 finally { 8069 dbg.exitRule(getGrammarFileName(), "switchLabel"); 8070 decRuleLevel(); 8071 if ( getRuleLevel()==0 ) {dbg.terminate();} 8072 } 8073 8074 return ; 8075 } 8076 // $ANTLR end "switchLabel" 8077 8078 8079 // $ANTLR start "trystatement" 8080 // src/com/google/doclava/parser/Java.g:887:1: trystatement : 'try' block ( catches 'finally' block | catches | 'finally' block ) ; 8081 public final void trystatement() throws RecognitionException { 8082 int trystatement_StartIndex = input.index(); 8083 try { dbg.enterRule(getGrammarFileName(), "trystatement"); 8084 if ( getRuleLevel()==0 ) {dbg.commence();} 8085 incRuleLevel(); 8086 dbg.location(887, 1); 8087 8088 try { 8089 if ( state.backtracking>0 && alreadyParsedRule(input, 62) ) { return ; } 8090 // src/com/google/doclava/parser/Java.g:888:5: ( 'try' block ( catches 'finally' block | catches | 'finally' block ) ) 8091 dbg.enterAlt(1); 8092 8093 // src/com/google/doclava/parser/Java.g:888:9: 'try' block ( catches 'finally' block | catches | 'finally' block ) 8094 { 8095 dbg.location(888,9); 8096 match(input,TRY,FOLLOW_TRY_in_trystatement4557); if (state.failed) return ; 8097 dbg.location(888,15); 8098 pushFollow(FOLLOW_block_in_trystatement4559); 8099 block(); 8100 8101 state._fsp--; 8102 if (state.failed) return ; 8103 dbg.location(889,9); 8104 // src/com/google/doclava/parser/Java.g:889:9: ( catches 'finally' block | catches | 'finally' block ) 8105 int alt102=3; 8106 try { dbg.enterSubRule(102); 8107 try { dbg.enterDecision(102, decisionCanBacktrack[102]); 8108 8109 int LA102_0 = input.LA(1); 8110 8111 if ( (LA102_0==CATCH) ) { 8112 int LA102_1 = input.LA(2); 8113 8114 if ( (synpred153_Java()) ) { 8115 alt102=1; 8116 } 8117 else if ( (synpred154_Java()) ) { 8118 alt102=2; 8119 } 8120 else { 8121 if (state.backtracking>0) {state.failed=true; return ;} 8122 NoViableAltException nvae = 8123 new NoViableAltException("", 102, 1, input); 8124 8125 dbg.recognitionException(nvae); 8126 throw nvae; 8127 } 8128 } 8129 else if ( (LA102_0==FINALLY) ) { 8130 alt102=3; 8131 } 8132 else { 8133 if (state.backtracking>0) {state.failed=true; return ;} 8134 NoViableAltException nvae = 8135 new NoViableAltException("", 102, 0, input); 8136 8137 dbg.recognitionException(nvae); 8138 throw nvae; 8139 } 8140 } finally {dbg.exitDecision(102);} 8141 8142 switch (alt102) { 8143 case 1 : 8144 dbg.enterAlt(1); 8145 8146 // src/com/google/doclava/parser/Java.g:889:13: catches 'finally' block 8147 { 8148 dbg.location(889,13); 8149 pushFollow(FOLLOW_catches_in_trystatement4573); 8150 catches(); 8151 8152 state._fsp--; 8153 if (state.failed) return ; 8154 dbg.location(889,21); 8155 match(input,FINALLY,FOLLOW_FINALLY_in_trystatement4575); if (state.failed) return ; 8156 dbg.location(889,31); 8157 pushFollow(FOLLOW_block_in_trystatement4577); 8158 block(); 8159 8160 state._fsp--; 8161 if (state.failed) return ; 8162 8163 } 8164 break; 8165 case 2 : 8166 dbg.enterAlt(2); 8167 8168 // src/com/google/doclava/parser/Java.g:890:13: catches 8169 { 8170 dbg.location(890,13); 8171 pushFollow(FOLLOW_catches_in_trystatement4591); 8172 catches(); 8173 8174 state._fsp--; 8175 if (state.failed) return ; 8176 8177 } 8178 break; 8179 case 3 : 8180 dbg.enterAlt(3); 8181 8182 // src/com/google/doclava/parser/Java.g:891:13: 'finally' block 8183 { 8184 dbg.location(891,13); 8185 match(input,FINALLY,FOLLOW_FINALLY_in_trystatement4605); if (state.failed) return ; 8186 dbg.location(891,23); 8187 pushFollow(FOLLOW_block_in_trystatement4607); 8188 block(); 8189 8190 state._fsp--; 8191 if (state.failed) return ; 8192 8193 } 8194 break; 8195 8196 } 8197 } finally {dbg.exitSubRule(102);} 8198 8199 8200 } 8201 8202 } 8203 catch (RecognitionException re) { 8204 reportError(re); 8205 recover(input,re); 8206 } 8207 finally { 8208 if ( state.backtracking>0 ) { memoize(input, 62, trystatement_StartIndex); } 8209 } 8210 dbg.location(893, 6); 8211 8212 } 8213 finally { 8214 dbg.exitRule(getGrammarFileName(), "trystatement"); 8215 decRuleLevel(); 8216 if ( getRuleLevel()==0 ) {dbg.terminate();} 8217 } 8218 8219 return ; 8220 } 8221 // $ANTLR end "trystatement" 8222 8223 8224 // $ANTLR start "catches" 8225 // src/com/google/doclava/parser/Java.g:895:1: catches : catchClause ( catchClause )* ; 8226 public final void catches() throws RecognitionException { 8227 int catches_StartIndex = input.index(); 8228 try { dbg.enterRule(getGrammarFileName(), "catches"); 8229 if ( getRuleLevel()==0 ) {dbg.commence();} 8230 incRuleLevel(); 8231 dbg.location(895, 1); 8232 8233 try { 8234 if ( state.backtracking>0 && alreadyParsedRule(input, 63) ) { return ; } 8235 // src/com/google/doclava/parser/Java.g:896:5: ( catchClause ( catchClause )* ) 8236 dbg.enterAlt(1); 8237 8238 // src/com/google/doclava/parser/Java.g:896:9: catchClause ( catchClause )* 8239 { 8240 dbg.location(896,9); 8241 pushFollow(FOLLOW_catchClause_in_catches4637); 8242 catchClause(); 8243 8244 state._fsp--; 8245 if (state.failed) return ; 8246 dbg.location(897,9); 8247 // src/com/google/doclava/parser/Java.g:897:9: ( catchClause )* 8248 try { dbg.enterSubRule(103); 8249 8250 loop103: 8251 do { 8252 int alt103=2; 8253 try { dbg.enterDecision(103, decisionCanBacktrack[103]); 8254 8255 int LA103_0 = input.LA(1); 8256 8257 if ( (LA103_0==CATCH) ) { 8258 alt103=1; 8259 } 8260 8261 8262 } finally {dbg.exitDecision(103);} 8263 8264 switch (alt103) { 8265 case 1 : 8266 dbg.enterAlt(1); 8267 8268 // src/com/google/doclava/parser/Java.g:897:10: catchClause 8269 { 8270 dbg.location(897,10); 8271 pushFollow(FOLLOW_catchClause_in_catches4648); 8272 catchClause(); 8273 8274 state._fsp--; 8275 if (state.failed) return ; 8276 8277 } 8278 break; 8279 8280 default : 8281 break loop103; 8282 } 8283 } while (true); 8284 } finally {dbg.exitSubRule(103);} 8285 8286 8287 } 8288 8289 } 8290 catch (RecognitionException re) { 8291 reportError(re); 8292 recover(input,re); 8293 } 8294 finally { 8295 if ( state.backtracking>0 ) { memoize(input, 63, catches_StartIndex); } 8296 } 8297 dbg.location(899, 5); 8298 8299 } 8300 finally { 8301 dbg.exitRule(getGrammarFileName(), "catches"); 8302 decRuleLevel(); 8303 if ( getRuleLevel()==0 ) {dbg.terminate();} 8304 } 8305 8306 return ; 8307 } 8308 // $ANTLR end "catches" 8309 8310 8311 // $ANTLR start "catchClause" 8312 // src/com/google/doclava/parser/Java.g:901:1: catchClause : 'catch' '(' formalParameter ')' block ; 8313 public final void catchClause() throws RecognitionException { 8314 int catchClause_StartIndex = input.index(); 8315 try { dbg.enterRule(getGrammarFileName(), "catchClause"); 8316 if ( getRuleLevel()==0 ) {dbg.commence();} 8317 incRuleLevel(); 8318 dbg.location(901, 1); 8319 8320 try { 8321 if ( state.backtracking>0 && alreadyParsedRule(input, 64) ) { return ; } 8322 // src/com/google/doclava/parser/Java.g:902:5: ( 'catch' '(' formalParameter ')' block ) 8323 dbg.enterAlt(1); 8324 8325 // src/com/google/doclava/parser/Java.g:902:9: 'catch' '(' formalParameter ')' block 8326 { 8327 dbg.location(902,9); 8328 match(input,CATCH,FOLLOW_CATCH_in_catchClause4678); if (state.failed) return ; 8329 dbg.location(902,17); 8330 match(input,LPAREN,FOLLOW_LPAREN_in_catchClause4680); if (state.failed) return ; 8331 dbg.location(902,21); 8332 pushFollow(FOLLOW_formalParameter_in_catchClause4682); 8333 formalParameter(); 8334 8335 state._fsp--; 8336 if (state.failed) return ; 8337 dbg.location(903,9); 8338 match(input,RPAREN,FOLLOW_RPAREN_in_catchClause4692); if (state.failed) return ; 8339 dbg.location(903,13); 8340 pushFollow(FOLLOW_block_in_catchClause4694); 8341 block(); 8342 8343 state._fsp--; 8344 if (state.failed) return ; 8345 8346 } 8347 8348 } 8349 catch (RecognitionException re) { 8350 reportError(re); 8351 recover(input,re); 8352 } 8353 finally { 8354 if ( state.backtracking>0 ) { memoize(input, 64, catchClause_StartIndex); } 8355 } 8356 dbg.location(904, 5); 8357 8358 } 8359 finally { 8360 dbg.exitRule(getGrammarFileName(), "catchClause"); 8361 decRuleLevel(); 8362 if ( getRuleLevel()==0 ) {dbg.terminate();} 8363 } 8364 8365 return ; 8366 } 8367 // $ANTLR end "catchClause" 8368 8369 8370 // $ANTLR start "formalParameter" 8371 // src/com/google/doclava/parser/Java.g:906:1: formalParameter : variableModifiers type IDENTIFIER ( '[' ']' )* ; 8372 public final void formalParameter() throws RecognitionException { 8373 int formalParameter_StartIndex = input.index(); 8374 try { dbg.enterRule(getGrammarFileName(), "formalParameter"); 8375 if ( getRuleLevel()==0 ) {dbg.commence();} 8376 incRuleLevel(); 8377 dbg.location(906, 1); 8378 8379 try { 8380 if ( state.backtracking>0 && alreadyParsedRule(input, 65) ) { return ; } 8381 // src/com/google/doclava/parser/Java.g:907:5: ( variableModifiers type IDENTIFIER ( '[' ']' )* ) 8382 dbg.enterAlt(1); 8383 8384 // src/com/google/doclava/parser/Java.g:907:9: variableModifiers type IDENTIFIER ( '[' ']' )* 8385 { 8386 dbg.location(907,9); 8387 pushFollow(FOLLOW_variableModifiers_in_formalParameter4713); 8388 variableModifiers(); 8389 8390 state._fsp--; 8391 if (state.failed) return ; 8392 dbg.location(907,27); 8393 pushFollow(FOLLOW_type_in_formalParameter4715); 8394 type(); 8395 8396 state._fsp--; 8397 if (state.failed) return ; 8398 dbg.location(907,32); 8399 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_formalParameter4717); if (state.failed) return ; 8400 dbg.location(908,9); 8401 // src/com/google/doclava/parser/Java.g:908:9: ( '[' ']' )* 8402 try { dbg.enterSubRule(104); 8403 8404 loop104: 8405 do { 8406 int alt104=2; 8407 try { dbg.enterDecision(104, decisionCanBacktrack[104]); 8408 8409 int LA104_0 = input.LA(1); 8410 8411 if ( (LA104_0==LBRACKET) ) { 8412 alt104=1; 8413 } 8414 8415 8416 } finally {dbg.exitDecision(104);} 8417 8418 switch (alt104) { 8419 case 1 : 8420 dbg.enterAlt(1); 8421 8422 // src/com/google/doclava/parser/Java.g:908:10: '[' ']' 8423 { 8424 dbg.location(908,10); 8425 match(input,LBRACKET,FOLLOW_LBRACKET_in_formalParameter4728); if (state.failed) return ; 8426 dbg.location(908,14); 8427 match(input,RBRACKET,FOLLOW_RBRACKET_in_formalParameter4730); if (state.failed) return ; 8428 8429 } 8430 break; 8431 8432 default : 8433 break loop104; 8434 } 8435 } while (true); 8436 } finally {dbg.exitSubRule(104);} 8437 8438 8439 } 8440 8441 } 8442 catch (RecognitionException re) { 8443 reportError(re); 8444 recover(input,re); 8445 } 8446 finally { 8447 if ( state.backtracking>0 ) { memoize(input, 65, formalParameter_StartIndex); } 8448 } 8449 dbg.location(910, 5); 8450 8451 } 8452 finally { 8453 dbg.exitRule(getGrammarFileName(), "formalParameter"); 8454 decRuleLevel(); 8455 if ( getRuleLevel()==0 ) {dbg.terminate();} 8456 } 8457 8458 return ; 8459 } 8460 // $ANTLR end "formalParameter" 8461 8462 8463 // $ANTLR start "forstatement" 8464 // src/com/google/doclava/parser/Java.g:912:1: forstatement : ( 'for' '(' variableModifiers type IDENTIFIER ':' expression ')' statement | 'for' '(' ( forInit )? ';' ( expression )? ';' ( expressionList )? ')' statement ); 8465 public final void forstatement() throws RecognitionException { 8466 int forstatement_StartIndex = input.index(); 8467 try { dbg.enterRule(getGrammarFileName(), "forstatement"); 8468 if ( getRuleLevel()==0 ) {dbg.commence();} 8469 incRuleLevel(); 8470 dbg.location(912, 1); 8471 8472 try { 8473 if ( state.backtracking>0 && alreadyParsedRule(input, 66) ) { return ; } 8474 // src/com/google/doclava/parser/Java.g:913:5: ( 'for' '(' variableModifiers type IDENTIFIER ':' expression ')' statement | 'for' '(' ( forInit )? ';' ( expression )? ';' ( expressionList )? ')' statement ) 8475 int alt108=2; 8476 try { dbg.enterDecision(108, decisionCanBacktrack[108]); 8477 8478 int LA108_0 = input.LA(1); 8479 8480 if ( (LA108_0==FOR) ) { 8481 int LA108_1 = input.LA(2); 8482 8483 if ( (synpred157_Java()) ) { 8484 alt108=1; 8485 } 8486 else if ( (true) ) { 8487 alt108=2; 8488 } 8489 else { 8490 if (state.backtracking>0) {state.failed=true; return ;} 8491 NoViableAltException nvae = 8492 new NoViableAltException("", 108, 1, input); 8493 8494 dbg.recognitionException(nvae); 8495 throw nvae; 8496 } 8497 } 8498 else { 8499 if (state.backtracking>0) {state.failed=true; return ;} 8500 NoViableAltException nvae = 8501 new NoViableAltException("", 108, 0, input); 8502 8503 dbg.recognitionException(nvae); 8504 throw nvae; 8505 } 8506 } finally {dbg.exitDecision(108);} 8507 8508 switch (alt108) { 8509 case 1 : 8510 dbg.enterAlt(1); 8511 8512 // src/com/google/doclava/parser/Java.g:915:9: 'for' '(' variableModifiers type IDENTIFIER ':' expression ')' statement 8513 { 8514 dbg.location(915,9); 8515 match(input,FOR,FOLLOW_FOR_in_forstatement4775); if (state.failed) return ; 8516 dbg.location(915,15); 8517 match(input,LPAREN,FOLLOW_LPAREN_in_forstatement4777); if (state.failed) return ; 8518 dbg.location(915,19); 8519 pushFollow(FOLLOW_variableModifiers_in_forstatement4779); 8520 variableModifiers(); 8521 8522 state._fsp--; 8523 if (state.failed) return ; 8524 dbg.location(915,37); 8525 pushFollow(FOLLOW_type_in_forstatement4781); 8526 type(); 8527 8528 state._fsp--; 8529 if (state.failed) return ; 8530 dbg.location(915,42); 8531 match(input,IDENTIFIER,FOLLOW_IDENTIFIER_in_forstatement4783); if (state.failed) return ; 8532 dbg.location(915,53); 8533 match(input,COLON,FOLLOW_COLON_in_forstatement4785); if (state.failed) return ; 8534 dbg.location(916,9); 8535 pushFollow(FOLLOW_expression_in_forstatement4795); 8536 expression(); 8537 8538 state._fsp--; 8539 if (state.failed) return ; 8540 dbg.location(916,20); 8541 match(input,RPAREN,FOLLOW_RPAREN_in_forstatement4797); if (state.failed) return ; 8542 dbg.location(916,24); 8543 pushFollow(FOLLOW_statement_in_forstatement4799); 8544 statement(); 8545 8546 state._fsp--; 8547 if (state.failed) return ; 8548 8549 } 8550 break; 8551 case 2 : 8552 dbg.enterAlt(2); 8553 8554 // src/com/google/doclava/parser/Java.g:919:9: 'for' '(' ( forInit )? ';' ( expression )? ';' ( expressionList )? ')' statement 8555 { 8556 dbg.location(919,9); 8557 match(input,FOR,FOLLOW_FOR_in_forstatement4819); if (state.failed) return ; 8558 dbg.location(919,15); 8559 match(input,LPAREN,FOLLOW_LPAREN_in_forstatement4821); if (state.failed) return ; 8560 dbg.location(920,17); 8561 // src/com/google/doclava/parser/Java.g:920:17: ( forInit )? 8562 int alt105=2; 8563 try { dbg.enterSubRule(105); 8564 try { dbg.enterDecision(105, decisionCanBacktrack[105]); 8565 8566 int LA105_0 = input.LA(1); 8567 8568 if ( ((LA105_0>=IDENTIFIER && LA105_0<=NULL)||LA105_0==BOOLEAN||LA105_0==BYTE||LA105_0==CHAR||LA105_0==DOUBLE||LA105_0==FINAL||LA105_0==FLOAT||LA105_0==INT||LA105_0==LONG||LA105_0==NEW||LA105_0==SHORT||LA105_0==SUPER||LA105_0==THIS||LA105_0==VOID||LA105_0==LPAREN||(LA105_0>=BANG && LA105_0<=TILDE)||(LA105_0>=PLUSPLUS && LA105_0<=SUB)||LA105_0==MONKEYS_AT) ) { 8569 alt105=1; 8570 } 8571 } finally {dbg.exitDecision(105);} 8572 8573 switch (alt105) { 8574 case 1 : 8575 dbg.enterAlt(1); 8576 8577 // src/com/google/doclava/parser/Java.g:920:18: forInit 8578 { 8579 dbg.location(920,18); 8580 pushFollow(FOLLOW_forInit_in_forstatement4840); 8581 forInit(); 8582 8583 state._fsp--; 8584 if (state.failed) return ; 8585 8586 } 8587 break; 8588 8589 } 8590 } finally {dbg.exitSubRule(105);} 8591 8592 dbg.location(921,20); 8593 match(input,SEMI,FOLLOW_SEMI_in_forstatement4861); if (state.failed) return ; 8594 dbg.location(922,17); 8595 // src/com/google/doclava/parser/Java.g:922:17: ( expression )? 8596 int alt106=2; 8597 try { dbg.enterSubRule(106); 8598 try { dbg.enterDecision(106, decisionCanBacktrack[106]); 8599 8600 int LA106_0 = input.LA(1); 8601 8602 if ( ((LA106_0>=IDENTIFIER && LA106_0<=NULL)||LA106_0==BOOLEAN||LA106_0==BYTE||LA106_0==CHAR||LA106_0==DOUBLE||LA106_0==FLOAT||LA106_0==INT||LA106_0==LONG||LA106_0==NEW||LA106_0==SHORT||LA106_0==SUPER||LA106_0==THIS||LA106_0==VOID||LA106_0==LPAREN||(LA106_0>=BANG && LA106_0<=TILDE)||(LA106_0>=PLUSPLUS && LA106_0<=SUB)) ) { 8603 alt106=1; 8604 } 8605 } finally {dbg.exitDecision(106);} 8606 8607 switch (alt106) { 8608 case 1 : 8609 dbg.enterAlt(1); 8610 8611 // src/com/google/doclava/parser/Java.g:922:18: expression 8612 { 8613 dbg.location(922,18); 8614 pushFollow(FOLLOW_expression_in_forstatement4880); 8615 expression(); 8616 8617 state._fsp--; 8618 if (state.failed) return ; 8619 8620 } 8621 break; 8622 8623 } 8624 } finally {dbg.exitSubRule(106);} 8625 8626 dbg.location(923,20); 8627 match(input,SEMI,FOLLOW_SEMI_in_forstatement4901); if (state.failed) return ; 8628 dbg.location(924,17); 8629 // src/com/google/doclava/parser/Java.g:924:17: ( expressionList )? 8630 int alt107=2; 8631 try { dbg.enterSubRule(107); 8632 try { dbg.enterDecision(107, decisionCanBacktrack[107]); 8633 8634 int LA107_0 = input.LA(1); 8635 8636 if ( ((LA107_0>=IDENTIFIER && LA107_0<=NULL)||LA107_0==BOOLEAN||LA107_0==BYTE||LA107_0==CHAR||LA107_0==DOUBLE||LA107_0==FLOAT||LA107_0==INT||LA107_0==LONG||LA107_0==NEW||LA107_0==SHORT||LA107_0==SUPER||LA107_0==THIS||LA107_0==VOID||LA107_0==LPAREN||(LA107_0>=BANG && LA107_0<=TILDE)||(LA107_0>=PLUSPLUS && LA107_0<=SUB)) ) { 8637 alt107=1; 8638 } 8639 } finally {dbg.exitDecision(107);} 8640 8641 switch (alt107) { 8642 case 1 : 8643 dbg.enterAlt(1); 8644 8645 // src/com/google/doclava/parser/Java.g:924:18: expressionList 8646 { 8647 dbg.location(924,18); 8648 pushFollow(FOLLOW_expressionList_in_forstatement4920); 8649 expressionList(); 8650 8651 state._fsp--; 8652 if (state.failed) return ; 8653 8654 } 8655 break; 8656 8657 } 8658 } finally {dbg.exitSubRule(107);} 8659 8660 dbg.location(925,20); 8661 match(input,RPAREN,FOLLOW_RPAREN_in_forstatement4941); if (state.failed) return ; 8662 dbg.location(925,24); 8663 pushFollow(FOLLOW_statement_in_forstatement4943); 8664 statement(); 8665 8666 state._fsp--; 8667 if (state.failed) return ; 8668 8669 } 8670 break; 8671 8672 } 8673 } 8674 catch (RecognitionException re) { 8675 reportError(re); 8676 recover(input,re); 8677 } 8678 finally { 8679 if ( state.backtracking>0 ) { memoize(input, 66, forstatement_StartIndex); } 8680 } 8681 dbg.location(926, 5); 8682 8683 } 8684 finally { 8685 dbg.exitRule(getGrammarFileName(), "forstatement"); 8686 decRuleLevel(); 8687 if ( getRuleLevel()==0 ) {dbg.terminate();} 8688 } 8689 8690 return ; 8691 } 8692 // $ANTLR end "forstatement" 8693 8694 8695 // $ANTLR start "forInit" 8696 // src/com/google/doclava/parser/Java.g:928:1: forInit : ( localVariableDeclaration | expressionList ); 8697 public final void forInit() throws RecognitionException { 8698 int forInit_StartIndex = input.index(); 8699 try { dbg.enterRule(getGrammarFileName(), "forInit"); 8700 if ( getRuleLevel()==0 ) {dbg.commence();} 8701 incRuleLevel(); 8702 dbg.location(928, 1); 8703 8704 try { 8705 if ( state.backtracking>0 && alreadyParsedRule(input, 67) ) { return ; } 8706 // src/com/google/doclava/parser/Java.g:929:5: ( localVariableDeclaration | expressionList ) 8707 int alt109=2; 8708 try { dbg.enterDecision(109, decisionCanBacktrack[109]); 8709 8710 try { 8711 isCyclicDecision = true; 8712 alt109 = dfa109.predict(input); 8713 } 8714 catch (NoViableAltException nvae) { 8715 dbg.recognitionException(nvae); 8716 throw nvae; 8717 } 8718 } finally {dbg.exitDecision(109);} 8719 8720 switch (alt109) { 8721 case 1 : 8722 dbg.enterAlt(1); 8723 8724 // src/com/google/doclava/parser/Java.g:929:9: localVariableDeclaration 8725 { 8726 dbg.location(929,9); 8727 pushFollow(FOLLOW_localVariableDeclaration_in_forInit4962); 8728 localVariableDeclaration(); 8729 8730 state._fsp--; 8731 if (state.failed) return ; 8732 8733 } 8734 break; 8735 case 2 : 8736 dbg.enterAlt(2); 8737 8738 // src/com/google/doclava/parser/Java.g:930:9: expressionList 8739 { 8740 dbg.location(930,9); 8741 pushFollow(FOLLOW_expressionList_in_forInit4972); 8742 expressionList(); 8743 8744 state._fsp--; 8745 if (state.failed) return ; 8746 8747 } 8748 break; 8749 8750 } 8751 } 8752 catch (RecognitionException re) { 8753 reportError(re); 8754 recover(input,re); 8755 } 8756 finally { 8757 if ( state.backtracking>0 ) { memoize(input, 67, forInit_StartIndex); } 8758 } 8759 dbg.location(931, 5); 8760 8761 } 8762 finally { 8763 dbg.exitRule(getGrammarFileName(), "forInit"); 8764 decRuleLevel(); 8765 if ( getRuleLevel()==0 ) {dbg.terminate();} 8766 } 8767 8768 return ; 8769 } 8770 // $ANTLR end "forInit" 8771 8772 8773 // $ANTLR start "parExpression" 8774 // src/com/google/doclava/parser/Java.g:933:1: parExpression : '(' expression ')' ; 8775 public final void parExpression() throws RecognitionException { 8776 int parExpression_StartIndex = input.index(); 8777 try { dbg.enterRule(getGrammarFileName(), "parExpression"); 8778 if ( getRuleLevel()==0 ) {dbg.commence();} 8779 incRuleLevel(); 8780 dbg.location(933, 1); 8781 8782 try { 8783 if ( state.backtracking>0 && alreadyParsedRule(input, 68) ) { return ; } 8784 // src/com/google/doclava/parser/Java.g:934:5: ( '(' expression ')' ) 8785 dbg.enterAlt(1); 8786 8787 // src/com/google/doclava/parser/Java.g:934:9: '(' expression ')' 8788 { 8789 dbg.location(934,9); 8790 match(input,LPAREN,FOLLOW_LPAREN_in_parExpression4991); if (state.failed) return ; 8791 dbg.location(934,13); 8792 pushFollow(FOLLOW_expression_in_parExpression4993); 8793 expression(); 8794 8795 state._fsp--; 8796 if (state.failed) return ; 8797 dbg.location(934,24); 8798 match(input,RPAREN,FOLLOW_RPAREN_in_parExpression4995); if (state.failed) return ; 8799 8800 } 8801 8802 } 8803 catch (RecognitionException re) { 8804 reportError(re); 8805 recover(input,re); 8806 } 8807 finally { 8808 if ( state.backtracking>0 ) { memoize(input, 68, parExpression_StartIndex); } 8809 } 8810 dbg.location(935, 5); 8811 8812 } 8813 finally { 8814 dbg.exitRule(getGrammarFileName(), "parExpression"); 8815 decRuleLevel(); 8816 if ( getRuleLevel()==0 ) {dbg.terminate();} 8817 } 8818 8819 return ; 8820 } 8821 // $ANTLR end "parExpression" 8822 8823 8824 // $ANTLR start "expressionList" 8825 // src/com/google/doclava/parser/Java.g:937:1: expressionList : expression ( ',' expression )* ; 8826 public final void expressionList() throws RecognitionException { 8827 int expressionList_StartIndex = input.index(); 8828 try { dbg.enterRule(getGrammarFileName(), "expressionList"); 8829 if ( getRuleLevel()==0 ) {dbg.commence();} 8830 incRuleLevel(); 8831 dbg.location(937, 1); 8832 8833 try { 8834 if ( state.backtracking>0 && alreadyParsedRule(input, 69) ) { return ; } 8835 // src/com/google/doclava/parser/Java.g:938:5: ( expression ( ',' expression )* ) 8836 dbg.enterAlt(1); 8837 8838 // src/com/google/doclava/parser/Java.g:938:9: expression ( ',' expression )* 8839 { 8840 dbg.location(938,9); 8841 pushFollow(FOLLOW_expression_in_expressionList5014); 8842 expression(); 8843 8844 state._fsp--; 8845 if (state.failed) return ; 8846 dbg.location(939,9); 8847 // src/com/google/doclava/parser/Java.g:939:9: ( ',' expression )* 8848 try { dbg.enterSubRule(110); 8849 8850 loop110: 8851 do { 8852 int alt110=2; 8853 try { dbg.enterDecision(110, decisionCanBacktrack[110]); 8854 8855 int LA110_0 = input.LA(1); 8856 8857 if ( (LA110_0==COMMA) ) { 8858 alt110=1; 8859 } 8860 8861 8862 } finally {dbg.exitDecision(110);} 8863 8864 switch (alt110) { 8865 case 1 : 8866 dbg.enterAlt(1); 8867 8868 // src/com/google/doclava/parser/Java.g:939:10: ',' expression 8869 { 8870 dbg.location(939,10); 8871 match(input,COMMA,FOLLOW_COMMA_in_expressionList5025); if (state.failed) return ; 8872 dbg.location(939,14); 8873 pushFollow(FOLLOW_expression_in_expressionList5027); 8874 expression(); 8875 8876 state._fsp--; 8877 if (state.failed) return ; 8878 8879 } 8880 break; 8881 8882 default : 8883 break loop110; 8884 } 8885 } while (true); 8886 } finally {dbg.exitSubRule(110);} 8887 8888 8889 } 8890 8891 } 8892 catch (RecognitionException re) { 8893 reportError(re); 8894 recover(input,re); 8895 } 8896 finally { 8897 if ( state.backtracking>0 ) { memoize(input, 69, expressionList_StartIndex); } 8898 } 8899 dbg.location(941, 5); 8900 8901 } 8902 finally { 8903 dbg.exitRule(getGrammarFileName(), "expressionList"); 8904 decRuleLevel(); 8905 if ( getRuleLevel()==0 ) {dbg.terminate();} 8906 } 8907 8908 return ; 8909 } 8910 // $ANTLR end "expressionList" 8911 8912 8913 // $ANTLR start "expression" 8914 // src/com/google/doclava/parser/Java.g:944:1: expression : conditionalExpression ( assignmentOperator expression )? ; 8915 public final void expression() throws RecognitionException { 8916 int expression_StartIndex = input.index(); 8917 try { dbg.enterRule(getGrammarFileName(), "expression"); 8918 if ( getRuleLevel()==0 ) {dbg.commence();} 8919 incRuleLevel(); 8920 dbg.location(944, 1); 8921 8922 try { 8923 if ( state.backtracking>0 && alreadyParsedRule(input, 70) ) { return ; } 8924 // src/com/google/doclava/parser/Java.g:945:5: ( conditionalExpression ( assignmentOperator expression )? ) 8925 dbg.enterAlt(1); 8926 8927 // src/com/google/doclava/parser/Java.g:945:9: conditionalExpression ( assignmentOperator expression )? 8928 { 8929 dbg.location(945,9); 8930 pushFollow(FOLLOW_conditionalExpression_in_expression5058); 8931 conditionalExpression(); 8932 8933 state._fsp--; 8934 if (state.failed) return ; 8935 dbg.location(946,9); 8936 // src/com/google/doclava/parser/Java.g:946:9: ( assignmentOperator expression )? 8937 int alt111=2; 8938 try { dbg.enterSubRule(111); 8939 try { dbg.enterDecision(111, decisionCanBacktrack[111]); 8940 8941 int LA111_0 = input.LA(1); 8942 8943 if ( (LA111_0==EQ||(LA111_0>=PLUSEQ && LA111_0<=PERCENTEQ)||(LA111_0>=GT && LA111_0<=LT)) ) { 8944 alt111=1; 8945 } 8946 } finally {dbg.exitDecision(111);} 8947 8948 switch (alt111) { 8949 case 1 : 8950 dbg.enterAlt(1); 8951 8952 // src/com/google/doclava/parser/Java.g:946:10: assignmentOperator expression 8953 { 8954 dbg.location(946,10); 8955 pushFollow(FOLLOW_assignmentOperator_in_expression5069); 8956 assignmentOperator(); 8957 8958 state._fsp--; 8959 if (state.failed) return ; 8960 dbg.location(946,29); 8961 pushFollow(FOLLOW_expression_in_expression5071); 8962 expression(); 8963 8964 state._fsp--; 8965 if (state.failed) return ; 8966 8967 } 8968 break; 8969 8970 } 8971 } finally {dbg.exitSubRule(111);} 8972 8973 8974 } 8975 8976 } 8977 catch (RecognitionException re) { 8978 reportError(re); 8979 recover(input,re); 8980 } 8981 finally { 8982 if ( state.backtracking>0 ) { memoize(input, 70, expression_StartIndex); } 8983 } 8984 dbg.location(948, 5); 8985 8986 } 8987 finally { 8988 dbg.exitRule(getGrammarFileName(), "expression"); 8989 decRuleLevel(); 8990 if ( getRuleLevel()==0 ) {dbg.terminate();} 8991 } 8992 8993 return ; 8994 } 8995 // $ANTLR end "expression" 8996 8997 8998 // $ANTLR start "assignmentOperator" 8999 // src/com/google/doclava/parser/Java.g:951:1: assignmentOperator : ( '=' | '+=' | '-=' | '*=' | '/=' | '&=' | '|=' | '^=' | '%=' | '<' '<' '=' | '>' '>' '>' '=' | '>' '>' '=' ); 9000 public final void assignmentOperator() throws RecognitionException { 9001 int assignmentOperator_StartIndex = input.index(); 9002 try { dbg.enterRule(getGrammarFileName(), "assignmentOperator"); 9003 if ( getRuleLevel()==0 ) {dbg.commence();} 9004 incRuleLevel(); 9005 dbg.location(951, 1); 9006 9007 try { 9008 if ( state.backtracking>0 && alreadyParsedRule(input, 71) ) { return ; } 9009 // src/com/google/doclava/parser/Java.g:952:5: ( '=' | '+=' | '-=' | '*=' | '/=' | '&=' | '|=' | '^=' | '%=' | '<' '<' '=' | '>' '>' '>' '=' | '>' '>' '=' ) 9010 int alt112=12; 9011 try { dbg.enterDecision(112, decisionCanBacktrack[112]); 9012 9013 try { 9014 isCyclicDecision = true; 9015 alt112 = dfa112.predict(input); 9016 } 9017 catch (NoViableAltException nvae) { 9018 dbg.recognitionException(nvae); 9019 throw nvae; 9020 } 9021 } finally {dbg.exitDecision(112);} 9022 9023 switch (alt112) { 9024 case 1 : 9025 dbg.enterAlt(1); 9026 9027 // src/com/google/doclava/parser/Java.g:952:9: '=' 9028 { 9029 dbg.location(952,9); 9030 match(input,EQ,FOLLOW_EQ_in_assignmentOperator5102); if (state.failed) return ; 9031 9032 } 9033 break; 9034 case 2 : 9035 dbg.enterAlt(2); 9036 9037 // src/com/google/doclava/parser/Java.g:953:9: '+=' 9038 { 9039 dbg.location(953,9); 9040 match(input,PLUSEQ,FOLLOW_PLUSEQ_in_assignmentOperator5112); if (state.failed) return ; 9041 9042 } 9043 break; 9044 case 3 : 9045 dbg.enterAlt(3); 9046 9047 // src/com/google/doclava/parser/Java.g:954:9: '-=' 9048 { 9049 dbg.location(954,9); 9050 match(input,SUBEQ,FOLLOW_SUBEQ_in_assignmentOperator5122); if (state.failed) return ; 9051 9052 } 9053 break; 9054 case 4 : 9055 dbg.enterAlt(4); 9056 9057 // src/com/google/doclava/parser/Java.g:955:9: '*=' 9058 { 9059 dbg.location(955,9); 9060 match(input,STAREQ,FOLLOW_STAREQ_in_assignmentOperator5132); if (state.failed) return ; 9061 9062 } 9063 break; 9064 case 5 : 9065 dbg.enterAlt(5); 9066 9067 // src/com/google/doclava/parser/Java.g:956:9: '/=' 9068 { 9069 dbg.location(956,9); 9070 match(input,SLASHEQ,FOLLOW_SLASHEQ_in_assignmentOperator5142); if (state.failed) return ; 9071 9072 } 9073 break; 9074 case 6 : 9075 dbg.enterAlt(6); 9076 9077 // src/com/google/doclava/parser/Java.g:957:9: '&=' 9078 { 9079 dbg.location(957,9); 9080 match(input,AMPEQ,FOLLOW_AMPEQ_in_assignmentOperator5152); if (state.failed) return ; 9081 9082 } 9083 break; 9084 case 7 : 9085 dbg.enterAlt(7); 9086 9087 // src/com/google/doclava/parser/Java.g:958:9: '|=' 9088 { 9089 dbg.location(958,9); 9090 match(input,BAREQ,FOLLOW_BAREQ_in_assignmentOperator5162); if (state.failed) return ; 9091 9092 } 9093 break; 9094 case 8 : 9095 dbg.enterAlt(8); 9096 9097 // src/com/google/doclava/parser/Java.g:959:9: '^=' 9098 { 9099 dbg.location(959,9); 9100 match(input,CARETEQ,FOLLOW_CARETEQ_in_assignmentOperator5172); if (state.failed) return ; 9101 9102 } 9103 break; 9104 case 9 : 9105 dbg.enterAlt(9); 9106 9107 // src/com/google/doclava/parser/Java.g:960:9: '%=' 9108 { 9109 dbg.location(960,9); 9110 match(input,PERCENTEQ,FOLLOW_PERCENTEQ_in_assignmentOperator5182); if (state.failed) return ; 9111 9112 } 9113 break; 9114 case 10 : 9115 dbg.enterAlt(10); 9116 9117 // src/com/google/doclava/parser/Java.g:961:10: '<' '<' '=' 9118 { 9119 dbg.location(961,10); 9120 match(input,LT,FOLLOW_LT_in_assignmentOperator5193); if (state.failed) return ; 9121 dbg.location(961,14); 9122 match(input,LT,FOLLOW_LT_in_assignmentOperator5195); if (state.failed) return ; 9123 dbg.location(961,18); 9124 match(input,EQ,FOLLOW_EQ_in_assignmentOperator5197); if (state.failed) return ; 9125 9126 } 9127 break; 9128 case 11 : 9129 dbg.enterAlt(11); 9130 9131 // src/com/google/doclava/parser/Java.g:962:10: '>' '>' '>' '=' 9132 { 9133 dbg.location(962,10); 9134 match(input,GT,FOLLOW_GT_in_assignmentOperator5208); if (state.failed) return ; 9135 dbg.location(962,14); 9136 match(input,GT,FOLLOW_GT_in_assignmentOperator5210); if (state.failed) return ; 9137 dbg.location(962,18); 9138 match(input,GT,FOLLOW_GT_in_assignmentOperator5212); if (state.failed) return ; 9139 dbg.location(962,22); 9140 match(input,EQ,FOLLOW_EQ_in_assignmentOperator5214); if (state.failed) return ; 9141 9142 } 9143 break; 9144 case 12 : 9145 dbg.enterAlt(12); 9146 9147 // src/com/google/doclava/parser/Java.g:963:10: '>' '>' '=' 9148 { 9149 dbg.location(963,10); 9150 match(input,GT,FOLLOW_GT_in_assignmentOperator5225); if (state.failed) return ; 9151 dbg.location(963,14); 9152 match(input,GT,FOLLOW_GT_in_assignmentOperator5227); if (state.failed) return ; 9153 dbg.location(963,18); 9154 match(input,EQ,FOLLOW_EQ_in_assignmentOperator5229); if (state.failed) return ; 9155 9156 } 9157 break; 9158 9159 } 9160 } 9161 catch (RecognitionException re) { 9162 reportError(re); 9163 recover(input,re); 9164 } 9165 finally { 9166 if ( state.backtracking>0 ) { memoize(input, 71, assignmentOperator_StartIndex); } 9167 } 9168 dbg.location(964, 5); 9169 9170 } 9171 finally { 9172 dbg.exitRule(getGrammarFileName(), "assignmentOperator"); 9173 decRuleLevel(); 9174 if ( getRuleLevel()==0 ) {dbg.terminate();} 9175 } 9176 9177 return ; 9178 } 9179 // $ANTLR end "assignmentOperator" 9180 9181 9182 // $ANTLR start "conditionalExpression" 9183 // src/com/google/doclava/parser/Java.g:967:1: conditionalExpression : conditionalOrExpression ( '?' expression ':' conditionalExpression )? ; 9184 public final void conditionalExpression() throws RecognitionException { 9185 int conditionalExpression_StartIndex = input.index(); 9186 try { dbg.enterRule(getGrammarFileName(), "conditionalExpression"); 9187 if ( getRuleLevel()==0 ) {dbg.commence();} 9188 incRuleLevel(); 9189 dbg.location(967, 1); 9190 9191 try { 9192 if ( state.backtracking>0 && alreadyParsedRule(input, 72) ) { return ; } 9193 // src/com/google/doclava/parser/Java.g:968:5: ( conditionalOrExpression ( '?' expression ':' conditionalExpression )? ) 9194 dbg.enterAlt(1); 9195 9196 // src/com/google/doclava/parser/Java.g:968:9: conditionalOrExpression ( '?' expression ':' conditionalExpression )? 9197 { 9198 dbg.location(968,9); 9199 pushFollow(FOLLOW_conditionalOrExpression_in_conditionalExpression5249); 9200 conditionalOrExpression(); 9201 9202 state._fsp--; 9203 if (state.failed) return ; 9204 dbg.location(969,9); 9205 // src/com/google/doclava/parser/Java.g:969:9: ( '?' expression ':' conditionalExpression )? 9206 int alt113=2; 9207 try { dbg.enterSubRule(113); 9208 try { dbg.enterDecision(113, decisionCanBacktrack[113]); 9209 9210 int LA113_0 = input.LA(1); 9211 9212 if ( (LA113_0==QUES) ) { 9213 alt113=1; 9214 } 9215 } finally {dbg.exitDecision(113);} 9216 9217 switch (alt113) { 9218 case 1 : 9219 dbg.enterAlt(1); 9220 9221 // src/com/google/doclava/parser/Java.g:969:10: '?' expression ':' conditionalExpression 9222 { 9223 dbg.location(969,10); 9224 match(input,QUES,FOLLOW_QUES_in_conditionalExpression5260); if (state.failed) return ; 9225 dbg.location(969,14); 9226 pushFollow(FOLLOW_expression_in_conditionalExpression5262); 9227 expression(); 9228 9229 state._fsp--; 9230 if (state.failed) return ; 9231 dbg.location(969,25); 9232 match(input,COLON,FOLLOW_COLON_in_conditionalExpression5264); if (state.failed) return ; 9233 dbg.location(969,29); 9234 pushFollow(FOLLOW_conditionalExpression_in_conditionalExpression5266); 9235 conditionalExpression(); 9236 9237 state._fsp--; 9238 if (state.failed) return ; 9239 9240 } 9241 break; 9242 9243 } 9244 } finally {dbg.exitSubRule(113);} 9245 9246 9247 } 9248 9249 } 9250 catch (RecognitionException re) { 9251 reportError(re); 9252 recover(input,re); 9253 } 9254 finally { 9255 if ( state.backtracking>0 ) { memoize(input, 72, conditionalExpression_StartIndex); } 9256 } 9257 dbg.location(971, 5); 9258 9259 } 9260 finally { 9261 dbg.exitRule(getGrammarFileName(), "conditionalExpression"); 9262 decRuleLevel(); 9263 if ( getRuleLevel()==0 ) {dbg.terminate();} 9264 } 9265 9266 return ; 9267 } 9268 // $ANTLR end "conditionalExpression" 9269 9270 9271 // $ANTLR start "conditionalOrExpression" 9272 // src/com/google/doclava/parser/Java.g:973:1: conditionalOrExpression : conditionalAndExpression ( '||' conditionalAndExpression )* ; 9273 public final void conditionalOrExpression() throws RecognitionException { 9274 int conditionalOrExpression_StartIndex = input.index(); 9275 try { dbg.enterRule(getGrammarFileName(), "conditionalOrExpression"); 9276 if ( getRuleLevel()==0 ) {dbg.commence();} 9277 incRuleLevel(); 9278 dbg.location(973, 1); 9279 9280 try { 9281 if ( state.backtracking>0 && alreadyParsedRule(input, 73) ) { return ; } 9282 // src/com/google/doclava/parser/Java.g:974:5: ( conditionalAndExpression ( '||' conditionalAndExpression )* ) 9283 dbg.enterAlt(1); 9284 9285 // src/com/google/doclava/parser/Java.g:974:9: conditionalAndExpression ( '||' conditionalAndExpression )* 9286 { 9287 dbg.location(974,9); 9288 pushFollow(FOLLOW_conditionalAndExpression_in_conditionalOrExpression5296); 9289 conditionalAndExpression(); 9290 9291 state._fsp--; 9292 if (state.failed) return ; 9293 dbg.location(975,9); 9294 // src/com/google/doclava/parser/Java.g:975:9: ( '||' conditionalAndExpression )* 9295 try { dbg.enterSubRule(114); 9296 9297 loop114: 9298 do { 9299 int alt114=2; 9300 try { dbg.enterDecision(114, decisionCanBacktrack[114]); 9301 9302 int LA114_0 = input.LA(1); 9303 9304 if ( (LA114_0==BARBAR) ) { 9305 alt114=1; 9306 } 9307 9308 9309 } finally {dbg.exitDecision(114);} 9310 9311 switch (alt114) { 9312 case 1 : 9313 dbg.enterAlt(1); 9314 9315 // src/com/google/doclava/parser/Java.g:975:10: '||' conditionalAndExpression 9316 { 9317 dbg.location(975,10); 9318 match(input,BARBAR,FOLLOW_BARBAR_in_conditionalOrExpression5307); if (state.failed) return ; 9319 dbg.location(975,15); 9320 pushFollow(FOLLOW_conditionalAndExpression_in_conditionalOrExpression5309); 9321 conditionalAndExpression(); 9322 9323 state._fsp--; 9324 if (state.failed) return ; 9325 9326 } 9327 break; 9328 9329 default : 9330 break loop114; 9331 } 9332 } while (true); 9333 } finally {dbg.exitSubRule(114);} 9334 9335 9336 } 9337 9338 } 9339 catch (RecognitionException re) { 9340 reportError(re); 9341 recover(input,re); 9342 } 9343 finally { 9344 if ( state.backtracking>0 ) { memoize(input, 73, conditionalOrExpression_StartIndex); } 9345 } 9346 dbg.location(977, 5); 9347 9348 } 9349 finally { 9350 dbg.exitRule(getGrammarFileName(), "conditionalOrExpression"); 9351 decRuleLevel(); 9352 if ( getRuleLevel()==0 ) {dbg.terminate();} 9353 } 9354 9355 return ; 9356 } 9357 // $ANTLR end "conditionalOrExpression" 9358 9359 9360 // $ANTLR start "conditionalAndExpression" 9361 // src/com/google/doclava/parser/Java.g:979:1: conditionalAndExpression : inclusiveOrExpression ( '&&' inclusiveOrExpression )* ; 9362 public final void conditionalAndExpression() throws RecognitionException { 9363 int conditionalAndExpression_StartIndex = input.index(); 9364 try { dbg.enterRule(getGrammarFileName(), "conditionalAndExpression"); 9365 if ( getRuleLevel()==0 ) {dbg.commence();} 9366 incRuleLevel(); 9367 dbg.location(979, 1); 9368 9369 try { 9370 if ( state.backtracking>0 && alreadyParsedRule(input, 74) ) { return ; } 9371 // src/com/google/doclava/parser/Java.g:980:5: ( inclusiveOrExpression ( '&&' inclusiveOrExpression )* ) 9372 dbg.enterAlt(1); 9373 9374 // src/com/google/doclava/parser/Java.g:980:9: inclusiveOrExpression ( '&&' inclusiveOrExpression )* 9375 { 9376 dbg.location(980,9); 9377 pushFollow(FOLLOW_inclusiveOrExpression_in_conditionalAndExpression5339); 9378 inclusiveOrExpression(); 9379 9380 state._fsp--; 9381 if (state.failed) return ; 9382 dbg.location(981,9); 9383 // src/com/google/doclava/parser/Java.g:981:9: ( '&&' inclusiveOrExpression )* 9384 try { dbg.enterSubRule(115); 9385 9386 loop115: 9387 do { 9388 int alt115=2; 9389 try { dbg.enterDecision(115, decisionCanBacktrack[115]); 9390 9391 int LA115_0 = input.LA(1); 9392 9393 if ( (LA115_0==AMPAMP) ) { 9394 alt115=1; 9395 } 9396 9397 9398 } finally {dbg.exitDecision(115);} 9399 9400 switch (alt115) { 9401 case 1 : 9402 dbg.enterAlt(1); 9403 9404 // src/com/google/doclava/parser/Java.g:981:10: '&&' inclusiveOrExpression 9405 { 9406 dbg.location(981,10); 9407 match(input,AMPAMP,FOLLOW_AMPAMP_in_conditionalAndExpression5350); if (state.failed) return ; 9408 dbg.location(981,15); 9409 pushFollow(FOLLOW_inclusiveOrExpression_in_conditionalAndExpression5352); 9410 inclusiveOrExpression(); 9411 9412 state._fsp--; 9413 if (state.failed) return ; 9414 9415 } 9416 break; 9417 9418 default : 9419 break loop115; 9420 } 9421 } while (true); 9422 } finally {dbg.exitSubRule(115);} 9423 9424 9425 } 9426 9427 } 9428 catch (RecognitionException re) { 9429 reportError(re); 9430 recover(input,re); 9431 } 9432 finally { 9433 if ( state.backtracking>0 ) { memoize(input, 74, conditionalAndExpression_StartIndex); } 9434 } 9435 dbg.location(983, 5); 9436 9437 } 9438 finally { 9439 dbg.exitRule(getGrammarFileName(), "conditionalAndExpression"); 9440 decRuleLevel(); 9441 if ( getRuleLevel()==0 ) {dbg.terminate();} 9442 } 9443 9444 return ; 9445 } 9446 // $ANTLR end "conditionalAndExpression" 9447 9448 9449 // $ANTLR start "inclusiveOrExpression" 9450 // src/com/google/doclava/parser/Java.g:985:1: inclusiveOrExpression : exclusiveOrExpression ( '|' exclusiveOrExpression )* ; 9451 public final void inclusiveOrExpression() throws RecognitionException { 9452 int inclusiveOrExpression_StartIndex = input.index(); 9453 try { dbg.enterRule(getGrammarFileName(), "inclusiveOrExpression"); 9454 if ( getRuleLevel()==0 ) {dbg.commence();} 9455 incRuleLevel(); 9456 dbg.location(985, 1); 9457 9458 try { 9459 if ( state.backtracking>0 && alreadyParsedRule(input, 75) ) { return ; } 9460 // src/com/google/doclava/parser/Java.g:986:5: ( exclusiveOrExpression ( '|' exclusiveOrExpression )* ) 9461 dbg.enterAlt(1); 9462 9463 // src/com/google/doclava/parser/Java.g:986:9: exclusiveOrExpression ( '|' exclusiveOrExpression )* 9464 { 9465 dbg.location(986,9); 9466 pushFollow(FOLLOW_exclusiveOrExpression_in_inclusiveOrExpression5382); 9467 exclusiveOrExpression(); 9468 9469 state._fsp--; 9470 if (state.failed) return ; 9471 dbg.location(987,9); 9472 // src/com/google/doclava/parser/Java.g:987:9: ( '|' exclusiveOrExpression )* 9473 try { dbg.enterSubRule(116); 9474 9475 loop116: 9476 do { 9477 int alt116=2; 9478 try { dbg.enterDecision(116, decisionCanBacktrack[116]); 9479 9480 int LA116_0 = input.LA(1); 9481 9482 if ( (LA116_0==BAR) ) { 9483 alt116=1; 9484 } 9485 9486 9487 } finally {dbg.exitDecision(116);} 9488 9489 switch (alt116) { 9490 case 1 : 9491 dbg.enterAlt(1); 9492 9493 // src/com/google/doclava/parser/Java.g:987:10: '|' exclusiveOrExpression 9494 { 9495 dbg.location(987,10); 9496 match(input,BAR,FOLLOW_BAR_in_inclusiveOrExpression5393); if (state.failed) return ; 9497 dbg.location(987,14); 9498 pushFollow(FOLLOW_exclusiveOrExpression_in_inclusiveOrExpression5395); 9499 exclusiveOrExpression(); 9500 9501 state._fsp--; 9502 if (state.failed) return ; 9503 9504 } 9505 break; 9506 9507 default : 9508 break loop116; 9509 } 9510 } while (true); 9511 } finally {dbg.exitSubRule(116);} 9512 9513 9514 } 9515 9516 } 9517 catch (RecognitionException re) { 9518 reportError(re); 9519 recover(input,re); 9520 } 9521 finally { 9522 if ( state.backtracking>0 ) { memoize(input, 75, inclusiveOrExpression_StartIndex); } 9523 } 9524 dbg.location(989, 5); 9525 9526 } 9527 finally { 9528 dbg.exitRule(getGrammarFileName(), "inclusiveOrExpression"); 9529 decRuleLevel(); 9530 if ( getRuleLevel()==0 ) {dbg.terminate();} 9531 } 9532 9533 return ; 9534 } 9535 // $ANTLR end "inclusiveOrExpression" 9536 9537 9538 // $ANTLR start "exclusiveOrExpression" 9539 // src/com/google/doclava/parser/Java.g:991:1: exclusiveOrExpression : andExpression ( '^' andExpression )* ; 9540 public final void exclusiveOrExpression() throws RecognitionException { 9541 int exclusiveOrExpression_StartIndex = input.index(); 9542 try { dbg.enterRule(getGrammarFileName(), "exclusiveOrExpression"); 9543 if ( getRuleLevel()==0 ) {dbg.commence();} 9544 incRuleLevel(); 9545 dbg.location(991, 1); 9546 9547 try { 9548 if ( state.backtracking>0 && alreadyParsedRule(input, 76) ) { return ; } 9549 // src/com/google/doclava/parser/Java.g:992:5: ( andExpression ( '^' andExpression )* ) 9550 dbg.enterAlt(1); 9551 9552 // src/com/google/doclava/parser/Java.g:992:9: andExpression ( '^' andExpression )* 9553 { 9554 dbg.location(992,9); 9555 pushFollow(FOLLOW_andExpression_in_exclusiveOrExpression5425); 9556 andExpression(); 9557 9558 state._fsp--; 9559 if (state.failed) return ; 9560 dbg.location(993,9); 9561 // src/com/google/doclava/parser/Java.g:993:9: ( '^' andExpression )* 9562 try { dbg.enterSubRule(117); 9563 9564 loop117: 9565 do { 9566 int alt117=2; 9567 try { dbg.enterDecision(117, decisionCanBacktrack[117]); 9568 9569 int LA117_0 = input.LA(1); 9570 9571 if ( (LA117_0==CARET) ) { 9572 alt117=1; 9573 } 9574 9575 9576 } finally {dbg.exitDecision(117);} 9577 9578 switch (alt117) { 9579 case 1 : 9580 dbg.enterAlt(1); 9581 9582 // src/com/google/doclava/parser/Java.g:993:10: '^' andExpression 9583 { 9584 dbg.location(993,10); 9585 match(input,CARET,FOLLOW_CARET_in_exclusiveOrExpression5436); if (state.failed) return ; 9586 dbg.location(993,14); 9587 pushFollow(FOLLOW_andExpression_in_exclusiveOrExpression5438); 9588 andExpression(); 9589 9590 state._fsp--; 9591 if (state.failed) return ; 9592 9593 } 9594 break; 9595 9596 default : 9597 break loop117; 9598 } 9599 } while (true); 9600 } finally {dbg.exitSubRule(117);} 9601 9602 9603 } 9604 9605 } 9606 catch (RecognitionException re) { 9607 reportError(re); 9608 recover(input,re); 9609 } 9610 finally { 9611 if ( state.backtracking>0 ) { memoize(input, 76, exclusiveOrExpression_StartIndex); } 9612 } 9613 dbg.location(995, 5); 9614 9615 } 9616 finally { 9617 dbg.exitRule(getGrammarFileName(), "exclusiveOrExpression"); 9618 decRuleLevel(); 9619 if ( getRuleLevel()==0 ) {dbg.terminate();} 9620 } 9621 9622 return ; 9623 } 9624 // $ANTLR end "exclusiveOrExpression" 9625 9626 9627 // $ANTLR start "andExpression" 9628 // src/com/google/doclava/parser/Java.g:997:1: andExpression : equalityExpression ( '&' equalityExpression )* ; 9629 public final void andExpression() throws RecognitionException { 9630 int andExpression_StartIndex = input.index(); 9631 try { dbg.enterRule(getGrammarFileName(), "andExpression"); 9632 if ( getRuleLevel()==0 ) {dbg.commence();} 9633 incRuleLevel(); 9634 dbg.location(997, 1); 9635 9636 try { 9637 if ( state.backtracking>0 && alreadyParsedRule(input, 77) ) { return ; } 9638 // src/com/google/doclava/parser/Java.g:998:5: ( equalityExpression ( '&' equalityExpression )* ) 9639 dbg.enterAlt(1); 9640 9641 // src/com/google/doclava/parser/Java.g:998:9: equalityExpression ( '&' equalityExpression )* 9642 { 9643 dbg.location(998,9); 9644 pushFollow(FOLLOW_equalityExpression_in_andExpression5468); 9645 equalityExpression(); 9646 9647 state._fsp--; 9648 if (state.failed) return ; 9649 dbg.location(999,9); 9650 // src/com/google/doclava/parser/Java.g:999:9: ( '&' equalityExpression )* 9651 try { dbg.enterSubRule(118); 9652 9653 loop118: 9654 do { 9655 int alt118=2; 9656 try { dbg.enterDecision(118, decisionCanBacktrack[118]); 9657 9658 int LA118_0 = input.LA(1); 9659 9660 if ( (LA118_0==AMP) ) { 9661 alt118=1; 9662 } 9663 9664 9665 } finally {dbg.exitDecision(118);} 9666 9667 switch (alt118) { 9668 case 1 : 9669 dbg.enterAlt(1); 9670 9671 // src/com/google/doclava/parser/Java.g:999:10: '&' equalityExpression 9672 { 9673 dbg.location(999,10); 9674 match(input,AMP,FOLLOW_AMP_in_andExpression5479); if (state.failed) return ; 9675 dbg.location(999,14); 9676 pushFollow(FOLLOW_equalityExpression_in_andExpression5481); 9677 equalityExpression(); 9678 9679 state._fsp--; 9680 if (state.failed) return ; 9681 9682 } 9683 break; 9684 9685 default : 9686 break loop118; 9687 } 9688 } while (true); 9689 } finally {dbg.exitSubRule(118);} 9690 9691 9692 } 9693 9694 } 9695 catch (RecognitionException re) { 9696 reportError(re); 9697 recover(input,re); 9698 } 9699 finally { 9700 if ( state.backtracking>0 ) { memoize(input, 77, andExpression_StartIndex); } 9701 } 9702 dbg.location(1001, 5); 9703 9704 } 9705 finally { 9706 dbg.exitRule(getGrammarFileName(), "andExpression"); 9707 decRuleLevel(); 9708 if ( getRuleLevel()==0 ) {dbg.terminate();} 9709 } 9710 9711 return ; 9712 } 9713 // $ANTLR end "andExpression" 9714 9715 9716 // $ANTLR start "equalityExpression" 9717 // src/com/google/doclava/parser/Java.g:1003:1: equalityExpression : instanceOfExpression ( ( '==' | '!=' ) instanceOfExpression )* ; 9718 public final void equalityExpression() throws RecognitionException { 9719 int equalityExpression_StartIndex = input.index(); 9720 try { dbg.enterRule(getGrammarFileName(), "equalityExpression"); 9721 if ( getRuleLevel()==0 ) {dbg.commence();} 9722 incRuleLevel(); 9723 dbg.location(1003, 1); 9724 9725 try { 9726 if ( state.backtracking>0 && alreadyParsedRule(input, 78) ) { return ; } 9727 // src/com/google/doclava/parser/Java.g:1004:5: ( instanceOfExpression ( ( '==' | '!=' ) instanceOfExpression )* ) 9728 dbg.enterAlt(1); 9729 9730 // src/com/google/doclava/parser/Java.g:1004:9: instanceOfExpression ( ( '==' | '!=' ) instanceOfExpression )* 9731 { 9732 dbg.location(1004,9); 9733 pushFollow(FOLLOW_instanceOfExpression_in_equalityExpression5511); 9734 instanceOfExpression(); 9735 9736 state._fsp--; 9737 if (state.failed) return ; 9738 dbg.location(1005,9); 9739 // src/com/google/doclava/parser/Java.g:1005:9: ( ( '==' | '!=' ) instanceOfExpression )* 9740 try { dbg.enterSubRule(119); 9741 9742 loop119: 9743 do { 9744 int alt119=2; 9745 try { dbg.enterDecision(119, decisionCanBacktrack[119]); 9746 9747 int LA119_0 = input.LA(1); 9748 9749 if ( (LA119_0==EQEQ||LA119_0==BANGEQ) ) { 9750 alt119=1; 9751 } 9752 9753 9754 } finally {dbg.exitDecision(119);} 9755 9756 switch (alt119) { 9757 case 1 : 9758 dbg.enterAlt(1); 9759 9760 // src/com/google/doclava/parser/Java.g:1006:13: ( '==' | '!=' ) instanceOfExpression 9761 { 9762 dbg.location(1006,13); 9763 if ( input.LA(1)==EQEQ||input.LA(1)==BANGEQ ) { 9764 input.consume(); 9765 state.errorRecovery=false;state.failed=false; 9766 } 9767 else { 9768 if (state.backtracking>0) {state.failed=true; return ;} 9769 MismatchedSetException mse = new MismatchedSetException(null,input); 9770 dbg.recognitionException(mse); 9771 throw mse; 9772 } 9773 9774 dbg.location(1009,13); 9775 pushFollow(FOLLOW_instanceOfExpression_in_equalityExpression5585); 9776 instanceOfExpression(); 9777 9778 state._fsp--; 9779 if (state.failed) return ; 9780 9781 } 9782 break; 9783 9784 default : 9785 break loop119; 9786 } 9787 } while (true); 9788 } finally {dbg.exitSubRule(119);} 9789 9790 9791 } 9792 9793 } 9794 catch (RecognitionException re) { 9795 reportError(re); 9796 recover(input,re); 9797 } 9798 finally { 9799 if ( state.backtracking>0 ) { memoize(input, 78, equalityExpression_StartIndex); } 9800 } 9801 dbg.location(1011, 5); 9802 9803 } 9804 finally { 9805 dbg.exitRule(getGrammarFileName(), "equalityExpression"); 9806 decRuleLevel(); 9807 if ( getRuleLevel()==0 ) {dbg.terminate();} 9808 } 9809 9810 return ; 9811 } 9812 // $ANTLR end "equalityExpression" 9813 9814 9815 // $ANTLR start "instanceOfExpression" 9816 // src/com/google/doclava/parser/Java.g:1013:1: instanceOfExpression : relationalExpression ( 'instanceof' type )? ; 9817 public final void instanceOfExpression() throws RecognitionException { 9818 int instanceOfExpression_StartIndex = input.index(); 9819 try { dbg.enterRule(getGrammarFileName(), "instanceOfExpression"); 9820 if ( getRuleLevel()==0 ) {dbg.commence();} 9821 incRuleLevel(); 9822 dbg.location(1013, 1); 9823 9824 try { 9825 if ( state.backtracking>0 && alreadyParsedRule(input, 79) ) { return ; } 9826 // src/com/google/doclava/parser/Java.g:1014:5: ( relationalExpression ( 'instanceof' type )? ) 9827 dbg.enterAlt(1); 9828 9829 // src/com/google/doclava/parser/Java.g:1014:9: relationalExpression ( 'instanceof' type )? 9830 { 9831 dbg.location(1014,9); 9832 pushFollow(FOLLOW_relationalExpression_in_instanceOfExpression5615); 9833 relationalExpression(); 9834 9835 state._fsp--; 9836 if (state.failed) return ; 9837 dbg.location(1015,9); 9838 // src/com/google/doclava/parser/Java.g:1015:9: ( 'instanceof' type )? 9839 int alt120=2; 9840 try { dbg.enterSubRule(120); 9841 try { dbg.enterDecision(120, decisionCanBacktrack[120]); 9842 9843 int LA120_0 = input.LA(1); 9844 9845 if ( (LA120_0==INSTANCEOF) ) { 9846 alt120=1; 9847 } 9848 } finally {dbg.exitDecision(120);} 9849 9850 switch (alt120) { 9851 case 1 : 9852 dbg.enterAlt(1); 9853 9854 // src/com/google/doclava/parser/Java.g:1015:10: 'instanceof' type 9855 { 9856 dbg.location(1015,10); 9857 match(input,INSTANCEOF,FOLLOW_INSTANCEOF_in_instanceOfExpression5626); if (state.failed) return ; 9858 dbg.location(1015,23); 9859 pushFollow(FOLLOW_type_in_instanceOfExpression5628); 9860 type(); 9861 9862 state._fsp--; 9863 if (state.failed) return ; 9864 9865 } 9866 break; 9867 9868 } 9869 } finally {dbg.exitSubRule(120);} 9870 9871 9872 } 9873 9874 } 9875 catch (RecognitionException re) { 9876 reportError(re); 9877 recover(input,re); 9878 } 9879 finally { 9880 if ( state.backtracking>0 ) { memoize(input, 79, instanceOfExpression_StartIndex); } 9881 } 9882 dbg.location(1017, 5); 9883 9884 } 9885 finally { 9886 dbg.exitRule(getGrammarFileName(), "instanceOfExpression"); 9887 decRuleLevel(); 9888 if ( getRuleLevel()==0 ) {dbg.terminate();} 9889 } 9890 9891 return ; 9892 } 9893 // $ANTLR end "instanceOfExpression" 9894 9895 9896 // $ANTLR start "relationalExpression" 9897 // src/com/google/doclava/parser/Java.g:1019:1: relationalExpression : shiftExpression ( relationalOp shiftExpression )* ; 9898 public final void relationalExpression() throws RecognitionException { 9899 int relationalExpression_StartIndex = input.index(); 9900 try { dbg.enterRule(getGrammarFileName(), "relationalExpression"); 9901 if ( getRuleLevel()==0 ) {dbg.commence();} 9902 incRuleLevel(); 9903 dbg.location(1019, 1); 9904 9905 try { 9906 if ( state.backtracking>0 && alreadyParsedRule(input, 80) ) { return ; } 9907 // src/com/google/doclava/parser/Java.g:1020:5: ( shiftExpression ( relationalOp shiftExpression )* ) 9908 dbg.enterAlt(1); 9909 9910 // src/com/google/doclava/parser/Java.g:1020:9: shiftExpression ( relationalOp shiftExpression )* 9911 { 9912 dbg.location(1020,9); 9913 pushFollow(FOLLOW_shiftExpression_in_relationalExpression5658); 9914 shiftExpression(); 9915 9916 state._fsp--; 9917 if (state.failed) return ; 9918 dbg.location(1021,9); 9919 // src/com/google/doclava/parser/Java.g:1021:9: ( relationalOp shiftExpression )* 9920 try { dbg.enterSubRule(121); 9921 9922 loop121: 9923 do { 9924 int alt121=2; 9925 try { dbg.enterDecision(121, decisionCanBacktrack[121]); 9926 9927 int LA121_0 = input.LA(1); 9928 9929 if ( (LA121_0==LT) ) { 9930 int LA121_2 = input.LA(2); 9931 9932 if ( ((LA121_2>=IDENTIFIER && LA121_2<=NULL)||LA121_2==BOOLEAN||LA121_2==BYTE||LA121_2==CHAR||LA121_2==DOUBLE||LA121_2==FLOAT||LA121_2==INT||LA121_2==LONG||LA121_2==NEW||LA121_2==SHORT||LA121_2==SUPER||LA121_2==THIS||LA121_2==VOID||LA121_2==LPAREN||(LA121_2>=EQ && LA121_2<=TILDE)||(LA121_2>=PLUSPLUS && LA121_2<=SUB)) ) { 9933 alt121=1; 9934 } 9935 9936 9937 } 9938 else if ( (LA121_0==GT) ) { 9939 int LA121_3 = input.LA(2); 9940 9941 if ( ((LA121_3>=IDENTIFIER && LA121_3<=NULL)||LA121_3==BOOLEAN||LA121_3==BYTE||LA121_3==CHAR||LA121_3==DOUBLE||LA121_3==FLOAT||LA121_3==INT||LA121_3==LONG||LA121_3==NEW||LA121_3==SHORT||LA121_3==SUPER||LA121_3==THIS||LA121_3==VOID||LA121_3==LPAREN||(LA121_3>=EQ && LA121_3<=TILDE)||(LA121_3>=PLUSPLUS && LA121_3<=SUB)) ) { 9942 alt121=1; 9943 } 9944 9945 9946 } 9947 9948 9949 } finally {dbg.exitDecision(121);} 9950 9951 switch (alt121) { 9952 case 1 : 9953 dbg.enterAlt(1); 9954 9955 // src/com/google/doclava/parser/Java.g:1021:10: relationalOp shiftExpression 9956 { 9957 dbg.location(1021,10); 9958 pushFollow(FOLLOW_relationalOp_in_relationalExpression5669); 9959 relationalOp(); 9960 9961 state._fsp--; 9962 if (state.failed) return ; 9963 dbg.location(1021,23); 9964 pushFollow(FOLLOW_shiftExpression_in_relationalExpression5671); 9965 shiftExpression(); 9966 9967 state._fsp--; 9968 if (state.failed) return ; 9969 9970 } 9971 break; 9972 9973 default : 9974 break loop121; 9975 } 9976 } while (true); 9977 } finally {dbg.exitSubRule(121);} 9978 9979 9980 } 9981 9982 } 9983 catch (RecognitionException re) { 9984 reportError(re); 9985 recover(input,re); 9986 } 9987 finally { 9988 if ( state.backtracking>0 ) { memoize(input, 80, relationalExpression_StartIndex); } 9989 } 9990 dbg.location(1023, 5); 9991 9992 } 9993 finally { 9994 dbg.exitRule(getGrammarFileName(), "relationalExpression"); 9995 decRuleLevel(); 9996 if ( getRuleLevel()==0 ) {dbg.terminate();} 9997 } 9998 9999 return ; 10000 } 10001 // $ANTLR end "relationalExpression" 10002 10003 10004 // $ANTLR start "relationalOp" 10005 // src/com/google/doclava/parser/Java.g:1025:1: relationalOp : ( '<' '=' | '>' '=' | '<' | '>' ); 10006 public final void relationalOp() throws RecognitionException { 10007 int relationalOp_StartIndex = input.index(); 10008 try { dbg.enterRule(getGrammarFileName(), "relationalOp"); 10009 if ( getRuleLevel()==0 ) {dbg.commence();} 10010 incRuleLevel(); 10011 dbg.location(1025, 1); 10012 10013 try { 10014 if ( state.backtracking>0 && alreadyParsedRule(input, 81) ) { return ; } 10015 // src/com/google/doclava/parser/Java.g:1026:5: ( '<' '=' | '>' '=' | '<' | '>' ) 10016 int alt122=4; 10017 try { dbg.enterDecision(122, decisionCanBacktrack[122]); 10018 10019 int LA122_0 = input.LA(1); 10020 10021 if ( (LA122_0==LT) ) { 10022 int LA122_1 = input.LA(2); 10023 10024 if ( (LA122_1==EQ) ) { 10025 alt122=1; 10026 } 10027 else if ( ((LA122_1>=IDENTIFIER && LA122_1<=NULL)||LA122_1==BOOLEAN||LA122_1==BYTE||LA122_1==CHAR||LA122_1==DOUBLE||LA122_1==FLOAT||LA122_1==INT||LA122_1==LONG||LA122_1==NEW||LA122_1==SHORT||LA122_1==SUPER||LA122_1==THIS||LA122_1==VOID||LA122_1==LPAREN||(LA122_1>=BANG && LA122_1<=TILDE)||(LA122_1>=PLUSPLUS && LA122_1<=SUB)) ) { 10028 alt122=3; 10029 } 10030 else { 10031 if (state.backtracking>0) {state.failed=true; return ;} 10032 NoViableAltException nvae = 10033 new NoViableAltException("", 122, 1, input); 10034 10035 dbg.recognitionException(nvae); 10036 throw nvae; 10037 } 10038 } 10039 else if ( (LA122_0==GT) ) { 10040 int LA122_2 = input.LA(2); 10041 10042 if ( (LA122_2==EQ) ) { 10043 alt122=2; 10044 } 10045 else if ( ((LA122_2>=IDENTIFIER && LA122_2<=NULL)||LA122_2==BOOLEAN||LA122_2==BYTE||LA122_2==CHAR||LA122_2==DOUBLE||LA122_2==FLOAT||LA122_2==INT||LA122_2==LONG||LA122_2==NEW||LA122_2==SHORT||LA122_2==SUPER||LA122_2==THIS||LA122_2==VOID||LA122_2==LPAREN||(LA122_2>=BANG && LA122_2<=TILDE)||(LA122_2>=PLUSPLUS && LA122_2<=SUB)) ) { 10046 alt122=4; 10047 } 10048 else { 10049 if (state.backtracking>0) {state.failed=true; return ;} 10050 NoViableAltException nvae = 10051 new NoViableAltException("", 122, 2, input); 10052 10053 dbg.recognitionException(nvae); 10054 throw nvae; 10055 } 10056 } 10057 else { 10058 if (state.backtracking>0) {state.failed=true; return ;} 10059 NoViableAltException nvae = 10060 new NoViableAltException("", 122, 0, input); 10061 10062 dbg.recognitionException(nvae); 10063 throw nvae; 10064 } 10065 } finally {dbg.exitDecision(122);} 10066 10067 switch (alt122) { 10068 case 1 : 10069 dbg.enterAlt(1); 10070 10071 // src/com/google/doclava/parser/Java.g:1026:10: '<' '=' 10072 { 10073 dbg.location(1026,10); 10074 match(input,LT,FOLLOW_LT_in_relationalOp5702); if (state.failed) return ; 10075 dbg.location(1026,14); 10076 match(input,EQ,FOLLOW_EQ_in_relationalOp5704); if (state.failed) return ; 10077 10078 } 10079 break; 10080 case 2 : 10081 dbg.enterAlt(2); 10082 10083 // src/com/google/doclava/parser/Java.g:1027:10: '>' '=' 10084 { 10085 dbg.location(1027,10); 10086 match(input,GT,FOLLOW_GT_in_relationalOp5715); if (state.failed) return ; 10087 dbg.location(1027,14); 10088 match(input,EQ,FOLLOW_EQ_in_relationalOp5717); if (state.failed) return ; 10089 10090 } 10091 break; 10092 case 3 : 10093 dbg.enterAlt(3); 10094 10095 // src/com/google/doclava/parser/Java.g:1028:9: '<' 10096 { 10097 dbg.location(1028,9); 10098 match(input,LT,FOLLOW_LT_in_relationalOp5727); if (state.failed) return ; 10099 10100 } 10101 break; 10102 case 4 : 10103 dbg.enterAlt(4); 10104 10105 // src/com/google/doclava/parser/Java.g:1029:9: '>' 10106 { 10107 dbg.location(1029,9); 10108 match(input,GT,FOLLOW_GT_in_relationalOp5737); if (state.failed) return ; 10109 10110 } 10111 break; 10112 10113 } 10114 } 10115 catch (RecognitionException re) { 10116 reportError(re); 10117 recover(input,re); 10118 } 10119 finally { 10120 if ( state.backtracking>0 ) { memoize(input, 81, relationalOp_StartIndex); } 10121 } 10122 dbg.location(1030, 5); 10123 10124 } 10125 finally { 10126 dbg.exitRule(getGrammarFileName(), "relationalOp"); 10127 decRuleLevel(); 10128 if ( getRuleLevel()==0 ) {dbg.terminate();} 10129 } 10130 10131 return ; 10132 } 10133 // $ANTLR end "relationalOp" 10134 10135 10136 // $ANTLR start "shiftExpression" 10137 // src/com/google/doclava/parser/Java.g:1032:1: shiftExpression : additiveExpression ( shiftOp additiveExpression )* ; 10138 public final void shiftExpression() throws RecognitionException { 10139 int shiftExpression_StartIndex = input.index(); 10140 try { dbg.enterRule(getGrammarFileName(), "shiftExpression"); 10141 if ( getRuleLevel()==0 ) {dbg.commence();} 10142 incRuleLevel(); 10143 dbg.location(1032, 1); 10144 10145 try { 10146 if ( state.backtracking>0 && alreadyParsedRule(input, 82) ) { return ; } 10147 // src/com/google/doclava/parser/Java.g:1033:5: ( additiveExpression ( shiftOp additiveExpression )* ) 10148 dbg.enterAlt(1); 10149 10150 // src/com/google/doclava/parser/Java.g:1033:9: additiveExpression ( shiftOp additiveExpression )* 10151 { 10152 dbg.location(1033,9); 10153 pushFollow(FOLLOW_additiveExpression_in_shiftExpression5756); 10154 additiveExpression(); 10155 10156 state._fsp--; 10157 if (state.failed) return ; 10158 dbg.location(1034,9); 10159 // src/com/google/doclava/parser/Java.g:1034:9: ( shiftOp additiveExpression )* 10160 try { dbg.enterSubRule(123); 10161 10162 loop123: 10163 do { 10164 int alt123=2; 10165 try { dbg.enterDecision(123, decisionCanBacktrack[123]); 10166 10167 int LA123_0 = input.LA(1); 10168 10169 if ( (LA123_0==LT) ) { 10170 int LA123_1 = input.LA(2); 10171 10172 if ( (LA123_1==LT) ) { 10173 int LA123_4 = input.LA(3); 10174 10175 if ( ((LA123_4>=IDENTIFIER && LA123_4<=NULL)||LA123_4==BOOLEAN||LA123_4==BYTE||LA123_4==CHAR||LA123_4==DOUBLE||LA123_4==FLOAT||LA123_4==INT||LA123_4==LONG||LA123_4==NEW||LA123_4==SHORT||LA123_4==SUPER||LA123_4==THIS||LA123_4==VOID||LA123_4==LPAREN||(LA123_4>=BANG && LA123_4<=TILDE)||(LA123_4>=PLUSPLUS && LA123_4<=SUB)) ) { 10176 alt123=1; 10177 } 10178 10179 10180 } 10181 10182 10183 } 10184 else if ( (LA123_0==GT) ) { 10185 int LA123_2 = input.LA(2); 10186 10187 if ( (LA123_2==GT) ) { 10188 int LA123_5 = input.LA(3); 10189 10190 if ( (LA123_5==GT) ) { 10191 int LA123_7 = input.LA(4); 10192 10193 if ( ((LA123_7>=IDENTIFIER && LA123_7<=NULL)||LA123_7==BOOLEAN||LA123_7==BYTE||LA123_7==CHAR||LA123_7==DOUBLE||LA123_7==FLOAT||LA123_7==INT||LA123_7==LONG||LA123_7==NEW||LA123_7==SHORT||LA123_7==SUPER||LA123_7==THIS||LA123_7==VOID||LA123_7==LPAREN||(LA123_7>=BANG && LA123_7<=TILDE)||(LA123_7>=PLUSPLUS && LA123_7<=SUB)) ) { 10194 alt123=1; 10195 } 10196 10197 10198 } 10199 else if ( ((LA123_5>=IDENTIFIER && LA123_5<=NULL)||LA123_5==BOOLEAN||LA123_5==BYTE||LA123_5==CHAR||LA123_5==DOUBLE||LA123_5==FLOAT||LA123_5==INT||LA123_5==LONG||LA123_5==NEW||LA123_5==SHORT||LA123_5==SUPER||LA123_5==THIS||LA123_5==VOID||LA123_5==LPAREN||(LA123_5>=BANG && LA123_5<=TILDE)||(LA123_5>=PLUSPLUS && LA123_5<=SUB)) ) { 10200 alt123=1; 10201 } 10202 10203 10204 } 10205 10206 10207 } 10208 10209 10210 } finally {dbg.exitDecision(123);} 10211 10212 switch (alt123) { 10213 case 1 : 10214 dbg.enterAlt(1); 10215 10216 // src/com/google/doclava/parser/Java.g:1034:10: shiftOp additiveExpression 10217 { 10218 dbg.location(1034,10); 10219 pushFollow(FOLLOW_shiftOp_in_shiftExpression5767); 10220 shiftOp(); 10221 10222 state._fsp--; 10223 if (state.failed) return ; 10224 dbg.location(1034,18); 10225 pushFollow(FOLLOW_additiveExpression_in_shiftExpression5769); 10226 additiveExpression(); 10227 10228 state._fsp--; 10229 if (state.failed) return ; 10230 10231 } 10232 break; 10233 10234 default : 10235 break loop123; 10236 } 10237 } while (true); 10238 } finally {dbg.exitSubRule(123);} 10239 10240 10241 } 10242 10243 } 10244 catch (RecognitionException re) { 10245 reportError(re); 10246 recover(input,re); 10247 } 10248 finally { 10249 if ( state.backtracking>0 ) { memoize(input, 82, shiftExpression_StartIndex); } 10250 } 10251 dbg.location(1036, 5); 10252 10253 } 10254 finally { 10255 dbg.exitRule(getGrammarFileName(), "shiftExpression"); 10256 decRuleLevel(); 10257 if ( getRuleLevel()==0 ) {dbg.terminate();} 10258 } 10259 10260 return ; 10261 } 10262 // $ANTLR end "shiftExpression" 10263 10264 10265 // $ANTLR start "shiftOp" 10266 // src/com/google/doclava/parser/Java.g:1039:1: shiftOp : ( '<' '<' | '>' '>' '>' | '>' '>' ); 10267 public final void shiftOp() throws RecognitionException { 10268 int shiftOp_StartIndex = input.index(); 10269 try { dbg.enterRule(getGrammarFileName(), "shiftOp"); 10270 if ( getRuleLevel()==0 ) {dbg.commence();} 10271 incRuleLevel(); 10272 dbg.location(1039, 1); 10273 10274 try { 10275 if ( state.backtracking>0 && alreadyParsedRule(input, 83) ) { return ; } 10276 // src/com/google/doclava/parser/Java.g:1040:5: ( '<' '<' | '>' '>' '>' | '>' '>' ) 10277 int alt124=3; 10278 try { dbg.enterDecision(124, decisionCanBacktrack[124]); 10279 10280 int LA124_0 = input.LA(1); 10281 10282 if ( (LA124_0==LT) ) { 10283