View Javadoc
1 // $ANTLR 2.7.2: "javadoc2.g" -> "JavaDocParser.java"$ 2 /* FOREGEJ - FOrmatting REfactoring GEnerating Java 3 * 4 * Copyright (C) 2003 Andreas Arrgard 5 * 6 * This library is free software; you can redistribute it and/or 7 * modify it under the terms of the GNU Lesser General Public 8 * License as published by the Free Software Foundation; either 9 * version 2.1 of the License, or (at your option) any later version. 10 * 11 * This library is distributed in the hope that it will be useful, 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 * Lesser General Public License for more details. 15 * 16 * You should have received a copy of the GNU Lesser General Public 17 * License along with this library; if not, write to the Free Software 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 */ 20 package com.octagroup.foregej.java.doc; 21 import antlr.TokenBuffer; 22 import antlr.TokenStreamException; 23 import antlr.Token; 24 import antlr.TokenStream; 25 import antlr.RecognitionException; 26 import antlr.NoViableAltException; 27 import antlr.ParserSharedInputState; 28 import antlr.collections.impl.BitSet; 29 import antlr.collections.AST; 30 import antlr.ASTFactory; 31 import antlr.ASTPair; 32 import antlr.collections.impl.ASTArray; 33 public class JavaDocParser extends JavaDocParserBase implements JavaDocTokenTypes 34 { 35 protected JavaDocParser(TokenBuffer tokenBuf,int k) 36 { 37 super(tokenBuf, k); 38 tokenNames=_tokenNames; 39 buildTokenTypeASTClassMap(); 40 astFactory=new ASTFactory(getTokenTypeToASTClassMap()); 41 } 42 public JavaDocParser(TokenBuffer tokenBuf) 43 { 44 this(tokenBuf, 2); 45 } 46 protected JavaDocParser(TokenStream lexer,int k) 47 { 48 super(lexer, k); 49 tokenNames=_tokenNames; 50 buildTokenTypeASTClassMap(); 51 astFactory=new ASTFactory(getTokenTypeToASTClassMap()); 52 } 53 public JavaDocParser(TokenStream lexer) 54 { 55 this(lexer, 2); 56 } 57 public JavaDocParser(ParserSharedInputState state) 58 { 59 super(state, 2); 60 tokenNames=_tokenNames; 61 buildTokenTypeASTClassMap(); 62 astFactory=new ASTFactory(getTokenTypeToASTClassMap()); 63 } 64 /*** 65 */ 66 public final void javadoc() throws RecognitionException, 67 TokenStreamException 68 { 69 returnAST=null; 70 ASTPair currentAST=new ASTPair(); 71 AST javadoc_AST=null; 72 AST jc_AST=null; 73 try{ 74 // for error handling 75 AST tmp1_AST=null; 76 tmp1_AST=astFactory.create(LT(1)); 77 match(OJAVADOC); 78 javadoc_content(); 79 jc_AST=(AST)returnAST; 80 AST tmp2_AST=null; 81 tmp2_AST=astFactory.create(LT(1)); 82 match(CJAVADOC); 83 javadoc_AST=(AST)currentAST.root; 84 javadoc_AST=(AST)astFactory.make((new ASTArray(2)).add(astFactory.create(JAVADOC, 85 "JAVADOC")).add(jc_AST)); 86 currentAST.root=javadoc_AST; 87 currentAST.child=((javadoc_AST!=null&& 88 javadoc_AST.getFirstChild()!=null)?javadoc_AST.getFirstChild():javadoc_AST); 89 currentAST.advanceChildToEnd(); 90 }catch (RecognitionException ex) { 91 reportError(ex); 92 consume(); 93 consumeUntil(_tokenSet_0); 94 } 95 returnAST=javadoc_AST; 96 } 97 /*** 98 */ 99 public final void javadoc_content() throws RecognitionException, 100 TokenStreamException 101 { 102 returnAST=null; 103 ASTPair currentAST=new ASTPair(); 104 AST javadoc_content_AST=null; 105 try{ 106 // for error handling 107 { 108 _loop4: 109 110 do { 111 switch(LA(1)) { 112 case AT: 113 114 { 115 jtag(); 116 astFactory.addASTChild(currentAST, 117 returnAST); 118 break; 119 } 120 case LITERAL_param: 121 case LITERAL_return: 122 case LITERAL_author: 123 case WORD: 124 case DQUOTE: 125 case SQUOTE: 126 case INT: 127 case MINUS: 128 case GT: 129 case EQUAL: 130 case OTHER_TOKEN: 131 case OBR: 132 case OPARA: 133 case OPRE: 134 case OCODE: 135 case OANCHOR: 136 case OITALIC: 137 case OBOLD: 138 case OUNDER: 139 140 { 141 body_content(); 142 astFactory.addASTChild(currentAST, 143 returnAST); 144 break; 145 } 146 default: 147 148 { 149 break _loop4; 150 } 151 } 152 } while(true); 153 154 } 155 javadoc_content_AST=(AST)currentAST.root; 156 }catch (RecognitionException ex) { 157 reportError(ex); 158 consume(); 159 consumeUntil(_tokenSet_1); 160 } 161 returnAST=javadoc_content_AST; 162 } 163 /*** 164 */ 165 public final void jtag() throws RecognitionException, 166 TokenStreamException 167 { 168 returnAST=null; 169 ASTPair currentAST=new ASTPair(); 170 AST jtag_AST=null; 171 try{ 172 // for error handling 173 if(LA(1)==AT&&LA(2)==LITERAL_param) { 174 jtag_param(); 175 astFactory.addASTChild(currentAST, returnAST); 176 jtag_AST=(AST)currentAST.root; 177 } else if(LA(1)==AT&&LA(2)==LITERAL_author) { 178 jtag_author(); 179 astFactory.addASTChild(currentAST, returnAST); 180 jtag_AST=(AST)currentAST.root; 181 } else if(LA(1)==AT&&LA(2)==LITERAL_return) { 182 jtag_return(); 183 astFactory.addASTChild(currentAST, returnAST); 184 jtag_AST=(AST)currentAST.root; 185 } else if(LA(1)==AT&&LA(2)==WORD) { 186 jtag_other(); 187 astFactory.addASTChild(currentAST, returnAST); 188 jtag_AST=(AST)currentAST.root; 189 } else { 190 throw new NoViableAltException(LT(1), getFilename()); 191 } 192 }catch (RecognitionException ex) { 193 reportError(ex); 194 consume(); 195 consumeUntil(_tokenSet_2); 196 } 197 returnAST=jtag_AST; 198 } 199 /*** 200 */ 201 public final void body_content() throws RecognitionException, 202 TokenStreamException 203 { 204 returnAST=null; 205 ASTPair currentAST=new ASTPair(); 206 AST body_content_AST=null; 207 try{ 208 // for error handling 209 switch(LA(1)) { 210 case OPARA: 211 case OPRE: 212 213 { 214 body_tag(); 215 astFactory.addASTChild(currentAST, returnAST); 216 body_content_AST=(AST)currentAST.root; 217 break; 218 } 219 case LITERAL_param: 220 case LITERAL_return: 221 case LITERAL_author: 222 case WORD: 223 case DQUOTE: 224 case SQUOTE: 225 case INT: 226 case MINUS: 227 case GT: 228 case EQUAL: 229 case OTHER_TOKEN: 230 case OBR: 231 case OCODE: 232 case OANCHOR: 233 case OITALIC: 234 case OBOLD: 235 case OUNDER: 236 237 { 238 text(); 239 astFactory.addASTChild(currentAST, returnAST); 240 body_content_AST=(AST)currentAST.root; 241 break; 242 } 243 default: 244 245 { 246 throw new NoViableAltException(LT(1), getFilename()); 247 } 248 } 249 }catch (RecognitionException ex) { 250 reportError(ex); 251 consume(); 252 consumeUntil(_tokenSet_2); 253 } 254 returnAST=body_content_AST; 255 } 256 /*** 257 */ 258 public final void jtag_param() throws RecognitionException, 259 TokenStreamException 260 { 261 returnAST=null; 262 ASTPair currentAST=new ASTPair(); 263 AST jtag_param_AST=null; 264 Token jt=null; 265 AST jt_AST=null; 266 try{ 267 // for error handling 268 match(AT); 269 jt=LT(1); 270 jt_AST=astFactory.create(jt); 271 astFactory.makeASTRoot(currentAST, jt_AST); 272 match(LITERAL_param); 273 jtag_data(); 274 astFactory.addASTChild(currentAST, returnAST); 275 jt_AST.setType(JTAG_PARAM); 276 jtag_param_AST=(AST)currentAST.root; 277 }catch (RecognitionException ex) { 278 reportError(ex); 279 consume(); 280 consumeUntil(_tokenSet_2); 281 } 282 returnAST=jtag_param_AST; 283 } 284 /*** 285 */ 286 public final void jtag_author() throws RecognitionException, 287 TokenStreamException 288 { 289 returnAST=null; 290 ASTPair currentAST=new ASTPair(); 291 AST jtag_author_AST=null; 292 Token jt=null; 293 AST jt_AST=null; 294 try{ 295 // for error handling 296 match(AT); 297 jt=LT(1); 298 jt_AST=astFactory.create(jt); 299 astFactory.makeASTRoot(currentAST, jt_AST); 300 match(LITERAL_author); 301 jtag_data(); 302 astFactory.addASTChild(currentAST, returnAST); 303 jt_AST.setType(JTAG_AUTHOR); 304 jtag_author_AST=(AST)currentAST.root; 305 }catch (RecognitionException ex) { 306 reportError(ex); 307 consume(); 308 consumeUntil(_tokenSet_2); 309 } 310 returnAST=jtag_author_AST; 311 } 312 /*** 313 */ 314 public final void jtag_return() throws RecognitionException, 315 TokenStreamException 316 { 317 returnAST=null; 318 ASTPair currentAST=new ASTPair(); 319 AST jtag_return_AST=null; 320 Token jt=null; 321 AST jt_AST=null; 322 try{ 323 // for error handling 324 match(AT); 325 jt=LT(1); 326 jt_AST=astFactory.create(jt); 327 astFactory.makeASTRoot(currentAST, jt_AST); 328 match(LITERAL_return); 329 jtag_data(); 330 astFactory.addASTChild(currentAST, returnAST); 331 jt_AST.setType(JTAG_RETURN); 332 jtag_return_AST=(AST)currentAST.root; 333 }catch (RecognitionException ex) { 334 reportError(ex); 335 consume(); 336 consumeUntil(_tokenSet_2); 337 } 338 returnAST=jtag_return_AST; 339 } 340 /*** 341 */ 342 public final void jtag_other() throws RecognitionException, 343 TokenStreamException 344 { 345 returnAST=null; 346 ASTPair currentAST=new ASTPair(); 347 AST jtag_other_AST=null; 348 Token jt=null; 349 AST jt_AST=null; 350 try{ 351 // for error handling 352 match(AT); 353 jt=LT(1); 354 jt_AST=astFactory.create(jt); 355 astFactory.makeASTRoot(currentAST, jt_AST); 356 match(WORD); 357 jtag_data(); 358 astFactory.addASTChild(currentAST, returnAST); 359 jt_AST.setType(JTAG); 360 jtag_other_AST=(AST)currentAST.root; 361 }catch (RecognitionException ex) { 362 reportError(ex); 363 consume(); 364 consumeUntil(_tokenSet_2); 365 } 366 returnAST=jtag_other_AST; 367 } 368 /*** 369 */ 370 public final void jtag_data() throws RecognitionException, 371 TokenStreamException 372 { 373 returnAST=null; 374 ASTPair currentAST=new ASTPair(); 375 AST jtag_data_AST=null; 376 try{ 377 // for error handling 378 { 379 _loop12: 380 381 do { 382 if(_tokenSet_3.member(LA(1))&&_tokenSet_2.member(LA(2))) { 383 text(); 384 astFactory.addASTChild(currentAST, returnAST); 385 } else { 386 break _loop12; 387 } 388 } while(true); 389 390 } 391 jtag_data_AST=(AST)currentAST.root; 392 }catch (RecognitionException ex) { 393 reportError(ex); 394 consume(); 395 consumeUntil(_tokenSet_2); 396 } 397 returnAST=jtag_data_AST; 398 } 399 /*** 400 */ 401 public final void text() throws RecognitionException, 402 TokenStreamException 403 { 404 returnAST=null; 405 ASTPair currentAST=new ASTPair(); 406 AST text_AST=null; 407 try{ 408 // for error handling 409 switch(LA(1)) { 410 case LITERAL_param: 411 case LITERAL_return: 412 case LITERAL_author: 413 case WORD: 414 case DQUOTE: 415 case SQUOTE: 416 case INT: 417 case MINUS: 418 case GT: 419 case EQUAL: 420 case OTHER_TOKEN: 421 422 { 423 pcdata(); 424 astFactory.addASTChild(currentAST, returnAST); 425 text_AST=(AST)currentAST.root; 426 break; 427 } 428 case OBR: 429 case OCODE: 430 case OANCHOR: 431 case OITALIC: 432 case OBOLD: 433 case OUNDER: 434 435 { 436 text_tag(); 437 astFactory.addASTChild(currentAST, returnAST); 438 text_AST=(AST)currentAST.root; 439 break; 440 } 441 default: 442 443 { 444 throw new NoViableAltException(LT(1), getFilename()); 445 } 446 } 447 }catch (RecognitionException ex) { 448 reportError(ex); 449 consume(); 450 consumeUntil(_tokenSet_4); 451 } 452 returnAST=text_AST; 453 } 454 /*** 455 */ 456 public final void pcdata() throws RecognitionException, 457 TokenStreamException 458 { 459 returnAST=null; 460 ASTPair currentAST=new ASTPair(); 461 AST pcdata_AST=null; 462 try{ 463 // for error handling 464 { 465 int _cnt15=0; 466 _loop15: 467 468 do { 469 if(_tokenSet_5.member(LA(1))&&LA(2)>=CJAVADOC&& 470 LA(2)<=CUNDER) { 471 pcdata_no_quote(); 472 astFactory.addASTChild(currentAST, returnAST); 473 } else if(LA(1)==DQUOTE&&LA(2)>=CJAVADOC&& 474 LA(2)<=CUNDER) { 475 AST tmp7_AST=null; 476 tmp7_AST=astFactory.create(LT(1)); 477 astFactory.addASTChild(currentAST, tmp7_AST); 478 match(DQUOTE); 479 } else if(LA(1)==SQUOTE&&LA(2)>=CJAVADOC&& 480 LA(2)<=CUNDER) { 481 AST tmp8_AST=null; 482 tmp8_AST=astFactory.create(LT(1)); 483 astFactory.addASTChild(currentAST, tmp8_AST); 484 match(SQUOTE); 485 } else { 486 if(_cnt15>=1) { 487 break _loop15; 488 } else { 489 throw new NoViableAltException(LT(1), 490 getFilename()); 491 } 492 } 493 _cnt15++; 494 } while(true); 495 496 } 497 pcdata_AST=(AST)currentAST.root; 498 }catch (RecognitionException ex) { 499 reportError(ex); 500 consume(); 501 consumeUntil(_tokenSet_4); 502 } 503 returnAST=pcdata_AST; 504 } 505 /*** 506 */ 507 public final void pcdata_no_quote() throws RecognitionException, 508 TokenStreamException 509 { 510 returnAST=null; 511 ASTPair currentAST=new ASTPair(); 512 AST pcdata_no_quote_AST=null; 513 try{ 514 // for error handling 515 { 516 int _cnt18=0; 517 _loop18: 518 519 do { 520 if(LA(1)==WORD&&LA(2)>=CJAVADOC&&LA(2)<=CUNDER) { 521 attr(); 522 astFactory.addASTChild(currentAST, returnAST); 523 } else if(LA(1)==WORD&&LA(2)>=CJAVADOC&& 524 LA(2)<=CUNDER) { 525 AST tmp9_AST=null; 526 tmp9_AST=astFactory.create(LT(1)); 527 astFactory.addASTChild(currentAST, tmp9_AST); 528 match(WORD); 529 } else if(LA(1)>=LITERAL_param&& 530 LA(1)<=LITERAL_author&&LA(2)>=CJAVADOC&& 531 LA(2)<=CUNDER) { 532 literal(); 533 astFactory.addASTChild(currentAST, returnAST); 534 } else if(LA(1)==INT&&LA(2)>=CJAVADOC&& 535 LA(2)<=CUNDER) { 536 AST tmp10_AST=null; 537 tmp10_AST=astFactory.create(LT(1)); 538 astFactory.addASTChild(currentAST, tmp10_AST); 539 match(INT); 540 } else if(LA(1)==MINUS&&LA(2)>=CJAVADOC&& 541 LA(2)<=CUNDER) { 542 AST tmp11_AST=null; 543 tmp11_AST=astFactory.create(LT(1)); 544 astFactory.addASTChild(currentAST, tmp11_AST); 545 match(MINUS); 546 } else if(LA(1)==GT&&LA(2)>=CJAVADOC&& 547 LA(2)<=CUNDER) { 548 AST tmp12_AST=null; 549 tmp12_AST=astFactory.create(LT(1)); 550 astFactory.addASTChild(currentAST, tmp12_AST); 551 match(GT); 552 } else if(LA(1)==EQUAL&&LA(2)>=CJAVADOC&& 553 LA(2)<=CUNDER) { 554 AST tmp13_AST=null; 555 tmp13_AST=astFactory.create(LT(1)); 556 astFactory.addASTChild(currentAST, tmp13_AST); 557 match(EQUAL); 558 } else if(LA(1)==OTHER_TOKEN&&LA(2)>=CJAVADOC&& 559 LA(2)<=CUNDER) { 560 AST tmp14_AST=null; 561 tmp14_AST=astFactory.create(LT(1)); 562 astFactory.addASTChild(currentAST, tmp14_AST); 563 match(OTHER_TOKEN); 564 } else { 565 if(_cnt18>=1) { 566 break _loop18; 567 } else { 568 throw new NoViableAltException(LT(1), 569 getFilename()); 570 } 571 } 572 _cnt18++; 573 } while(true); 574 575 } 576 pcdata_no_quote_AST=(AST)currentAST.root; 577 }catch (RecognitionException ex) { 578 reportError(ex); 579 consume(); 580 consumeUntil(_tokenSet_4); 581 } 582 returnAST=pcdata_no_quote_AST; 583 } 584 /*** 585 */ 586 public final void attr() throws RecognitionException, 587 TokenStreamException 588 { 589 returnAST=null; 590 ASTPair currentAST=new ASTPair(); 591 AST attr_AST=null; 592 Token a=null; 593 AST a_AST=null; 594 try{ 595 // for error handling 596 a=LT(1); 597 a_AST=astFactory.create(a); 598 astFactory.makeASTRoot(currentAST, a_AST); 599 match(WORD); 600 { 601 if(LA(1)==EQUAL&&LA(2)>=WORD&&LA(2)<=INT) { 602 AST tmp15_AST=null; 603 tmp15_AST=astFactory.create(LT(1)); 604 astFactory.addASTChild(currentAST, tmp15_AST); 605 match(EQUAL); 606 { 607 switch(LA(1)) { 608 case WORD: 609 610 { 611 AST tmp16_AST=null; 612 tmp16_AST=astFactory.create(LT(1)); 613 astFactory.addASTChild(currentAST, 614 tmp16_AST); 615 match(WORD); 616 break; 617 } 618 case INT: 619 620 { 621 AST tmp17_AST=null; 622 tmp17_AST=astFactory.create(LT(1)); 623 astFactory.addASTChild(currentAST, 624 tmp17_AST); 625 match(INT); 626 break; 627 } 628 case DQUOTE: 629 case SQUOTE: 630 631 { 632 string(); 633 astFactory.addASTChild(currentAST, 634 returnAST); 635 break; 636 } 637 default: 638 639 { 640 throw new NoViableAltException(LT(1), 641 getFilename()); 642 } 643 } 644 } 645 a_AST.setType(ATTRIBUTE); 646 } else if(LA(1)>=CJAVADOC&& 647 LA(1)<=CUNDER&&_tokenSet_6.member(LA(2))) { 648 } else { 649 throw new NoViableAltException(LT(1), getFilename()); 650 } 651 } 652 attr_AST=(AST)currentAST.root; 653 }catch (RecognitionException ex) { 654 reportError(ex); 655 consume(); 656 consumeUntil(_tokenSet_4); 657 } 658 returnAST=attr_AST; 659 } 660 /*** 661 */ 662 public final void literal() throws RecognitionException, 663 TokenStreamException 664 { 665 returnAST=null; 666 ASTPair currentAST=new ASTPair(); 667 AST literal_AST=null; 668 try{ 669 // for error handling 670 switch(LA(1)) { 671 case LITERAL_author: 672 673 { 674 AST tmp18_AST=null; 675 tmp18_AST=astFactory.create(LT(1)); 676 astFactory.addASTChild(currentAST, tmp18_AST); 677 match(LITERAL_author); 678 literal_AST=(AST)currentAST.root; 679 break; 680 } 681 case LITERAL_param: 682 683 { 684 AST tmp19_AST=null; 685 tmp19_AST=astFactory.create(LT(1)); 686 astFactory.addASTChild(currentAST, tmp19_AST); 687 match(LITERAL_param); 688 literal_AST=(AST)currentAST.root; 689 break; 690 } 691 case LITERAL_return: 692 693 { 694 AST tmp20_AST=null; 695 tmp20_AST=astFactory.create(LT(1)); 696 astFactory.addASTChild(currentAST, tmp20_AST); 697 match(LITERAL_return); 698 literal_AST=(AST)currentAST.root; 699 break; 700 } 701 default: 702 703 { 704 throw new NoViableAltException(LT(1), getFilename()); 705 } 706 } 707 }catch (RecognitionException ex) { 708 reportError(ex); 709 consume(); 710 consumeUntil(_tokenSet_4); 711 } 712 returnAST=literal_AST; 713 } 714 /*** 715 */ 716 public final void font() throws RecognitionException, 717 TokenStreamException 718 { 719 returnAST=null; 720 ASTPair currentAST=new ASTPair(); 721 AST font_AST=null; 722 try{ 723 // for error handling 724 switch(LA(1)) { 725 case OITALIC: 726 727 { 728 italic(); 729 astFactory.addASTChild(currentAST, returnAST); 730 font_AST=(AST)currentAST.root; 731 break; 732 } 733 case OBOLD: 734 735 { 736 bold(); 737 astFactory.addASTChild(currentAST, returnAST); 738 font_AST=(AST)currentAST.root; 739 break; 740 } 741 case OUNDER: 742 743 { 744 underline(); 745 astFactory.addASTChild(currentAST, returnAST); 746 font_AST=(AST)currentAST.root; 747 break; 748 } 749 default: 750 751 { 752 throw new NoViableAltException(LT(1), getFilename()); 753 } 754 } 755 }catch (RecognitionException ex) { 756 reportError(ex); 757 consume(); 758 consumeUntil(_tokenSet_4); 759 } 760 returnAST=font_AST; 761 } 762 /*** 763 */ 764 public final void italic() throws RecognitionException, 765 TokenStreamException 766 { 767 returnAST=null; 768 ASTPair currentAST=new ASTPair(); 769 AST italic_AST=null; 770 AST o_AST=null; 771 AST d_AST=null; 772 AST c_AST=null; 773 try{ 774 // for error handling 775 { 776 oitalic(); 777 o_AST=(AST)returnAST; 778 } 779 { 780 text_repeat(); 781 d_AST=(AST)returnAST; 782 } 783 { 784 citalic(); 785 c_AST=(AST)returnAST; 786 } 787 italic_AST=(AST)currentAST.root; 788 italic_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(ITALIC, 789 "ITALIC")).add(o_AST).add(d_AST).add(c_AST)); 790 currentAST.root=italic_AST; 791 currentAST.child=((italic_AST!=null&& 792 italic_AST.getFirstChild()!=null)?italic_AST.getFirstChild():italic_AST); 793 currentAST.advanceChildToEnd(); 794 }catch (RecognitionException ex) { 795 reportError(ex); 796 consume(); 797 consumeUntil(_tokenSet_4); 798 } 799 returnAST=italic_AST; 800 } 801 /*** 802 */ 803 public final void bold() throws RecognitionException, 804 TokenStreamException 805 { 806 returnAST=null; 807 ASTPair currentAST=new ASTPair(); 808 AST bold_AST=null; 809 AST o_AST=null; 810 AST d_AST=null; 811 AST c_AST=null; 812 try{ 813 // for error handling 814 { 815 obold(); 816 o_AST=(AST)returnAST; 817 } 818 { 819 text_repeat(); 820 d_AST=(AST)returnAST; 821 } 822 { 823 cbold(); 824 c_AST=(AST)returnAST; 825 } 826 bold_AST=(AST)currentAST.root; 827 bold_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(BOLD, 828 "BOLD")).add(o_AST).add(d_AST).add(c_AST)); 829 currentAST.root=bold_AST; 830 currentAST.child=((bold_AST!=null&& 831 bold_AST.getFirstChild()!=null)?bold_AST.getFirstChild():bold_AST); 832 currentAST.advanceChildToEnd(); 833 }catch (RecognitionException ex) { 834 reportError(ex); 835 consume(); 836 consumeUntil(_tokenSet_4); 837 } 838 returnAST=bold_AST; 839 } 840 /*** 841 */ 842 public final void underline() throws RecognitionException, 843 TokenStreamException 844 { 845 returnAST=null; 846 ASTPair currentAST=new ASTPair(); 847 AST underline_AST=null; 848 AST o_AST=null; 849 AST d_AST=null; 850 AST c_AST=null; 851 try{ 852 // for error handling 853 { 854 ounder(); 855 o_AST=(AST)returnAST; 856 } 857 { 858 text_repeat(); 859 d_AST=(AST)returnAST; 860 } 861 { 862 cunder(); 863 c_AST=(AST)returnAST; 864 } 865 underline_AST=(AST)currentAST.root; 866 underline_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(UNDERLINE, 867 "UNDERLINE")).add(o_AST).add(d_AST).add(c_AST)); 868 currentAST.root=underline_AST; 869 currentAST.child=((underline_AST!=null&& 870 underline_AST.getFirstChild()!=null)?underline_AST.getFirstChild():underline_AST); 871 currentAST.advanceChildToEnd(); 872 }catch (RecognitionException ex) { 873 reportError(ex); 874 consume(); 875 consumeUntil(_tokenSet_4); 876 } 877 returnAST=underline_AST; 878 } 879 /*** 880 */ 881 public final void phrase() throws RecognitionException, 882 TokenStreamException 883 { 884 returnAST=null; 885 ASTPair currentAST=new ASTPair(); 886 AST phrase_AST=null; 887 try{ 888 // for error handling 889 code(); 890 astFactory.addASTChild(currentAST, returnAST); 891 phrase_AST=(AST)currentAST.root; 892 }catch (RecognitionException ex) { 893 reportError(ex); 894 consume(); 895 consumeUntil(_tokenSet_4); 896 } 897 returnAST=phrase_AST; 898 } 899 /*** 900 */ 901 public final void code() throws RecognitionException, 902 TokenStreamException 903 { 904 returnAST=null; 905 ASTPair currentAST=new ASTPair(); 906 AST code_AST=null; 907 AST o_AST=null; 908 AST d_AST=null; 909 AST c_AST=null; 910 try{ 911 // for error handling 912 { 913 ocode(); 914 o_AST=(AST)returnAST; 915 } 916 { 917 text_repeat(); 918 d_AST=(AST)returnAST; 919 } 920 { 921 ccode(); 922 c_AST=(AST)returnAST; 923 } 924 code_AST=(AST)currentAST.root; 925 code_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(CODE, 926 "CODE")).add(o_AST).add(d_AST).add(c_AST)); 927 currentAST.root=code_AST; 928 currentAST.child=((code_AST!=null&& 929 code_AST.getFirstChild()!=null)?code_AST.getFirstChild():code_AST); 930 currentAST.advanceChildToEnd(); 931 }catch (RecognitionException ex) { 932 reportError(ex); 933 consume(); 934 consumeUntil(_tokenSet_4); 935 } 936 returnAST=code_AST; 937 } 938 /*** 939 */ 940 public final void special() throws RecognitionException, 941 TokenStreamException 942 { 943 returnAST=null; 944 ASTPair currentAST=new ASTPair(); 945 AST special_AST=null; 946 try{ 947 // for error handling 948 switch(LA(1)) { 949 case OANCHOR: 950 951 { 952 anchor(); 953 astFactory.addASTChild(currentAST, returnAST); 954 special_AST=(AST)currentAST.root; 955 break; 956 } 957 case OBR: 958 959 { 960 br(); 961 astFactory.addASTChild(currentAST, returnAST); 962 special_AST=(AST)currentAST.root; 963 break; 964 } 965 default: 966 967 { 968 throw new NoViableAltException(LT(1), getFilename()); 969 } 970 } 971 }catch (RecognitionException ex) { 972 reportError(ex); 973 consume(); 974 consumeUntil(_tokenSet_4); 975 } 976 returnAST=special_AST; 977 } 978 /*** 979 */ 980 public final void anchor() throws RecognitionException, 981 TokenStreamException 982 { 983 returnAST=null; 984 ASTPair currentAST=new ASTPair(); 985 AST anchor_AST=null; 986 AST o_AST=null; 987 AST d_AST=null; 988 AST c_AST=null; 989 try{ 990 // for error handling 991 { 992 oanchor(); 993 o_AST=(AST)returnAST; 994 } 995 { 996 text_repeat(); 997 d_AST=(AST)returnAST; 998 } 999 { 1000 canchor(); 1001 c_AST=(AST)returnAST; 1002 } 1003 anchor_AST=(AST)currentAST.root; 1004 anchor_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(ANCHOR, 1005 "ANCHOR")).add(o_AST).add(d_AST).add(c_AST)); 1006 currentAST.root=anchor_AST; 1007 currentAST.child=((anchor_AST!=null&& 1008 anchor_AST.getFirstChild()!=null)?anchor_AST.getFirstChild():anchor_AST); 1009 currentAST.advanceChildToEnd(); 1010 }catch (RecognitionException ex) { 1011 reportError(ex); 1012 consume(); 1013 consumeUntil(_tokenSet_4); 1014 } 1015 returnAST=anchor_AST; 1016 } 1017 /*** 1018 */ 1019 public final void br() throws RecognitionException, 1020 TokenStreamException 1021 { 1022 returnAST=null; 1023 ASTPair currentAST=new ASTPair(); 1024 AST br_AST=null; 1025 try{ 1026 // for error handling 1027 AST tmp21_AST=null; 1028 tmp21_AST=astFactory.create(LT(1)); 1029 astFactory.makeASTRoot(currentAST, tmp21_AST); 1030 match(OBR); 1031 { 1032 _loop71: 1033 1034 do { 1035 if(LA(1)==WORD) { 1036 attr(); 1037 astFactory.addASTChild(currentAST, returnAST); 1038 } else { 1039 break _loop71; 1040 } 1041 } while(true); 1042 1043 } 1044 match(GT); 1045 br_AST=(AST)currentAST.root; 1046 }catch (RecognitionException ex) { 1047 reportError(ex); 1048 consume(); 1049 consumeUntil(_tokenSet_4); 1050 } 1051 returnAST=br_AST; 1052 } 1053 /*** 1054 */ 1055 public final void text_tag() throws RecognitionException, 1056 TokenStreamException 1057 { 1058 returnAST=null; 1059 ASTPair currentAST=new ASTPair(); 1060 AST text_tag_AST=null; 1061 try{ 1062 // for error handling 1063 switch(LA(1)) { 1064 case OITALIC: 1065 case OBOLD: 1066 case OUNDER: 1067 1068 { 1069 font(); 1070 astFactory.addASTChild(currentAST, returnAST); 1071 text_tag_AST=(AST)currentAST.root; 1072 break; 1073 } 1074 case OCODE: 1075 1076 { 1077 phrase(); 1078 astFactory.addASTChild(currentAST, returnAST); 1079 text_tag_AST=(AST)currentAST.root; 1080 break; 1081 } 1082 case OBR: 1083 case OANCHOR: 1084 1085 { 1086 special(); 1087 astFactory.addASTChild(currentAST, returnAST); 1088 text_tag_AST=(AST)currentAST.root; 1089 break; 1090 } 1091 default: 1092 1093 { 1094 throw new NoViableAltException(LT(1), getFilename()); 1095 } 1096 } 1097 }catch (RecognitionException ex) { 1098 reportError(ex); 1099 consume(); 1100 consumeUntil(_tokenSet_4); 1101 } 1102 returnAST=text_tag_AST; 1103 } 1104 /*** 1105 */ 1106 public final void block() throws RecognitionException, 1107 TokenStreamException 1108 { 1109 returnAST=null; 1110 ASTPair currentAST=new ASTPair(); 1111 AST block_AST=null; 1112 try{ 1113 // for error handling 1114 switch(LA(1)) { 1115 case OPARA: 1116 1117 { 1118 paragraph(); 1119 astFactory.addASTChild(currentAST, returnAST); 1120 block_AST=(AST)currentAST.root; 1121 break; 1122 } 1123 case OPRE: 1124 1125 { 1126 preformatted(); 1127 astFactory.addASTChild(currentAST, returnAST); 1128 block_AST=(AST)currentAST.root; 1129 break; 1130 } 1131 default: 1132 1133 { 1134 throw new NoViableAltException(LT(1), getFilename()); 1135 } 1136 } 1137 }catch (RecognitionException ex) { 1138 reportError(ex); 1139 consume(); 1140 consumeUntil(_tokenSet_2); 1141 } 1142 returnAST=block_AST; 1143 } 1144 /*** 1145 */ 1146 public final void paragraph() throws RecognitionException, 1147 TokenStreamException 1148 { 1149 returnAST=null; 1150 ASTPair currentAST=new ASTPair(); 1151 AST paragraph_AST=null; 1152 AST o_AST=null; 1153 AST d_AST=null; 1154 AST c_AST=null; 1155 try{ 1156 // for error handling 1157 { 1158 opara(); 1159 o_AST=(AST)returnAST; 1160 } 1161 { 1162 text_repeat(); 1163 d_AST=(AST)returnAST; 1164 } 1165 { 1166 switch(LA(1)) { 1167 case CPARA: 1168 1169 { 1170 cpara(); 1171 c_AST=(AST)returnAST; 1172 break; 1173 } 1174 case CJAVADOC: 1175 case AT: 1176 case LITERAL_param: 1177 case LITERAL_return: 1178 case LITERAL_author: 1179 case WORD: 1180 case DQUOTE: 1181 case SQUOTE: 1182 case INT: 1183 case MINUS: 1184 case GT: 1185 case EQUAL: 1186 case OTHER_TOKEN: 1187 case OBR: 1188 case OPARA: 1189 case OPRE: 1190 case OCODE: 1191 case OANCHOR: 1192 case OITALIC: 1193 case OBOLD: 1194 case OUNDER: 1195 1196 { 1197 break; 1198 } 1199 default: 1200 1201 { 1202 throw new NoViableAltException(LT(1), 1203 getFilename()); 1204 } 1205 } 1206 } 1207 paragraph_AST=(AST)currentAST.root; 1208 paragraph_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(PARAGRAPH, 1209 "PARAGRAPH")).add(o_AST).add(d_AST).add(c_AST)); 1210 currentAST.root=paragraph_AST; 1211 currentAST.child=((paragraph_AST!=null&& 1212 paragraph_AST.getFirstChild()!=null)?paragraph_AST.getFirstChild():paragraph_AST); 1213 currentAST.advanceChildToEnd(); 1214 }catch (RecognitionException ex) { 1215 reportError(ex); 1216 consume(); 1217 consumeUntil(_tokenSet_2); 1218 } 1219 returnAST=paragraph_AST; 1220 } 1221 /*** 1222 */ 1223 public final void preformatted() throws RecognitionException, 1224 TokenStreamException 1225 { 1226 returnAST=null; 1227 ASTPair currentAST=new ASTPair(); 1228 AST preformatted_AST=null; 1229 AST o_AST=null; 1230 AST d_AST=null; 1231 AST c_AST=null; 1232 try{ 1233 // for error handling 1234 { 1235 opre(); 1236 o_AST=(AST)returnAST; 1237 } 1238 { 1239 text_repeat(); 1240 d_AST=(AST)returnAST; 1241 } 1242 { 1243 switch(LA(1)) { 1244 case CPRE: 1245 1246 { 1247 cpre(); 1248 c_AST=(AST)returnAST; 1249 break; 1250 } 1251 case CJAVADOC: 1252 case AT: 1253 case LITERAL_param: 1254 case LITERAL_return: 1255 case LITERAL_author: 1256 case WORD: 1257 case DQUOTE: 1258 case SQUOTE: 1259 case INT: 1260 case MINUS: 1261 case GT: 1262 case EQUAL: 1263 case OTHER_TOKEN: 1264 case OBR: 1265 case OPARA: 1266 case OPRE: 1267 case OCODE: 1268 case OANCHOR: 1269 case OITALIC: 1270 case OBOLD: 1271 case OUNDER: 1272 1273 { 1274 break; 1275 } 1276 default: 1277 1278 { 1279 throw new NoViableAltException(LT(1), 1280 getFilename()); 1281 } 1282 } 1283 } 1284 preformatted_AST=(AST)currentAST.root; 1285 preformatted_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(PREFORMATTED, 1286 "PREFORMATTED")).add(o_AST).add(d_AST).add(c_AST)); 1287 currentAST.root=preformatted_AST; 1288 currentAST.child=((preformatted_AST!=null&& 1289 preformatted_AST.getFirstChild()!=null)?preformatted_AST.getFirstChild():preformatted_AST); 1290 currentAST.advanceChildToEnd(); 1291 }catch (RecognitionException ex) { 1292 reportError(ex); 1293 consume(); 1294 consumeUntil(_tokenSet_2); 1295 } 1296 returnAST=preformatted_AST; 1297 } 1298 /*** 1299 */ 1300 public final void body_tag() throws RecognitionException, 1301 TokenStreamException 1302 { 1303 returnAST=null; 1304 ASTPair currentAST=new ASTPair(); 1305 AST body_tag_AST=null; 1306 try{ 1307 // for error handling 1308 block(); 1309 astFactory.addASTChild(currentAST, returnAST); 1310 body_tag_AST=(AST)currentAST.root; 1311 }catch (RecognitionException ex) { 1312 reportError(ex); 1313 consume(); 1314 consumeUntil(_tokenSet_2); 1315 } 1316 returnAST=body_tag_AST; 1317 } 1318 /*** 1319 */ 1320 public final void opara() throws RecognitionException, 1321 TokenStreamException 1322 { 1323 returnAST=null; 1324 ASTPair currentAST=new ASTPair(); 1325 AST opara_AST=null; 1326 try{ 1327 // for error handling 1328 AST tmp23_AST=null; 1329 tmp23_AST=astFactory.create(LT(1)); 1330 astFactory.makeASTRoot(currentAST, tmp23_AST); 1331 match(OPARA); 1332 { 1333 _loop74: 1334 1335 do { 1336 if(LA(1)==WORD) { 1337 attr(); 1338 astFactory.addASTChild(currentAST, returnAST); 1339 } else { 1340 break _loop74; 1341 } 1342 } while(true); 1343 1344 } 1345 match(GT); 1346 opara_AST=(AST)currentAST.root; 1347 }catch (RecognitionException ex) { 1348 reportError(ex); 1349 consume(); 1350 consumeUntil(_tokenSet_7); 1351 } 1352 returnAST=opara_AST; 1353 } 1354 /*** 1355 */ 1356 public final void text_repeat() throws RecognitionException, 1357 TokenStreamException 1358 { 1359 returnAST=null; 1360 ASTPair currentAST=new ASTPair(); 1361 AST text_repeat_AST=null; 1362 try{ 1363 // for error handling 1364 { 1365 _loop57: 1366 1367 do { 1368 if(_tokenSet_3.member(LA(1))&&LA(2)>=CJAVADOC&& 1369 LA(2)<=CUNDER) { 1370 text(); 1371 astFactory.addASTChild(currentAST, returnAST); 1372 } else { 1373 break _loop57; 1374 } 1375 } while(true); 1376 1377 } 1378 text_repeat_AST=(AST)currentAST.root; 1379 }catch (RecognitionException ex) { 1380 reportError(ex); 1381 consume(); 1382 consumeUntil(_tokenSet_4); 1383 } 1384 returnAST=text_repeat_AST; 1385 } 1386 /*** 1387 */ 1388 public final void cpara() throws RecognitionException, 1389 TokenStreamException 1390 { 1391 returnAST=null; 1392 ASTPair currentAST=new ASTPair(); 1393 AST cpara_AST=null; 1394 try{ 1395 // for error handling 1396 AST tmp25_AST=null; 1397 tmp25_AST=astFactory.create(LT(1)); 1398 astFactory.makeASTRoot(currentAST, tmp25_AST); 1399 match(CPARA); 1400 { 1401 _loop77: 1402 1403 do { 1404 if(LA(1)==WORD) { 1405 attr(); 1406 astFactory.addASTChild(currentAST, returnAST); 1407 } else { 1408 break _loop77; 1409 } 1410 } while(true); 1411 1412 } 1413 match(GT); 1414 cpara_AST=(AST)currentAST.root; 1415 }catch (RecognitionException ex) { 1416 reportError(ex); 1417 consume(); 1418 consumeUntil(_tokenSet_2); 1419 } 1420 returnAST=cpara_AST; 1421 } 1422 /*** 1423 */ 1424 public final void opre() throws RecognitionException, 1425 TokenStreamException 1426 { 1427 returnAST=null; 1428 ASTPair currentAST=new ASTPair(); 1429 AST opre_AST=null; 1430 try{ 1431 // for error handling 1432 AST tmp27_AST=null; 1433 tmp27_AST=astFactory.create(LT(1)); 1434 astFactory.makeASTRoot(currentAST, tmp27_AST); 1435 match(OPRE); 1436 { 1437 _loop80: 1438 1439 do { 1440 if(LA(1)==WORD) { 1441 attr(); 1442 astFactory.addASTChild(currentAST, returnAST); 1443 } else { 1444 break _loop80; 1445 } 1446 } while(true); 1447 1448 } 1449 match(GT); 1450 opre_AST=(AST)currentAST.root; 1451 }catch (RecognitionException ex) { 1452 reportError(ex); 1453 consume(); 1454 consumeUntil(_tokenSet_8); 1455 } 1456 returnAST=opre_AST; 1457 } 1458 /*** 1459 */ 1460 public final void cpre() throws RecognitionException, 1461 TokenStreamException 1462 { 1463 returnAST=null; 1464 ASTPair currentAST=new ASTPair(); 1465 AST cpre_AST=null; 1466 try{ 1467 // for error handling 1468 AST tmp29_AST=null; 1469 tmp29_AST=astFactory.create(LT(1)); 1470 astFactory.makeASTRoot(currentAST, tmp29_AST); 1471 match(CPRE); 1472 { 1473 _loop83: 1474 1475 do { 1476 if(LA(1)==WORD) { 1477 attr(); 1478 astFactory.addASTChild(currentAST, returnAST); 1479 } else { 1480 break _loop83; 1481 } 1482 } while(true); 1483 1484 } 1485 match(GT); 1486 cpre_AST=(AST)currentAST.root; 1487 }catch (RecognitionException ex) { 1488 reportError(ex); 1489 consume(); 1490 consumeUntil(_tokenSet_2); 1491 } 1492 returnAST=cpre_AST; 1493 } 1494 /*** 1495 */ 1496 public final void oitalic() throws RecognitionException, 1497 TokenStreamException 1498 { 1499 returnAST=null; 1500 ASTPair currentAST=new ASTPair(); 1501 AST oitalic_AST=null; 1502 try{ 1503 // for error handling 1504 AST tmp31_AST=null; 1505 tmp31_AST=astFactory.create(LT(1)); 1506 astFactory.makeASTRoot(currentAST, tmp31_AST); 1507 match(OITALIC); 1508 { 1509 _loop98: 1510 1511 do { 1512 if(LA(1)==WORD) { 1513 attr(); 1514 astFactory.addASTChild(currentAST, returnAST); 1515 } else { 1516 break _loop98; 1517 } 1518 } while(true); 1519 1520 } 1521 match(GT); 1522 oitalic_AST=(AST)currentAST.root; 1523 }catch (RecognitionException ex) { 1524 reportError(ex); 1525 consume(); 1526 consumeUntil(_tokenSet_9); 1527 } 1528 returnAST=oitalic_AST; 1529 } 1530 /*** 1531 */ 1532 public final void citalic() throws RecognitionException, 1533 TokenStreamException 1534 { 1535 returnAST=null; 1536 ASTPair currentAST=new ASTPair(); 1537 AST citalic_AST=null; 1538 try{ 1539 // for error handling 1540 AST tmp33_AST=null; 1541 tmp33_AST=astFactory.create(LT(1)); 1542 astFactory.makeASTRoot(currentAST, tmp33_AST); 1543 match(CITALIC); 1544 { 1545 _loop101: 1546 1547 do { 1548 if(LA(1)==WORD) { 1549 attr(); 1550 astFactory.addASTChild(currentAST, returnAST); 1551 } else { 1552 break _loop101; 1553 } 1554 } while(true); 1555 1556 } 1557 match(GT); 1558 citalic_AST=(AST)currentAST.root; 1559 }catch (RecognitionException ex) { 1560 reportError(ex); 1561 consume(); 1562 consumeUntil(_tokenSet_4); 1563 } 1564 returnAST=citalic_AST; 1565 } 1566 /*** 1567 */ 1568 public final void obold() throws RecognitionException, 1569 TokenStreamException 1570 { 1571 returnAST=null; 1572 ASTPair currentAST=new ASTPair(); 1573 AST obold_AST=null; 1574 try{ 1575 // for error handling 1576 AST tmp35_AST=null; 1577 tmp35_AST=astFactory.create(LT(1)); 1578 astFactory.makeASTRoot(currentAST, tmp35_AST); 1579 match(OBOLD); 1580 { 1581 _loop104: 1582 1583 do { 1584 if(LA(1)==WORD) { 1585 attr(); 1586 astFactory.addASTChild(currentAST, returnAST); 1587 } else { 1588 break _loop104; 1589 } 1590 } while(true); 1591 1592 } 1593 match(GT); 1594 obold_AST=(AST)currentAST.root; 1595 }catch (RecognitionException ex) { 1596 reportError(ex); 1597 consume(); 1598 consumeUntil(_tokenSet_10); 1599 } 1600 returnAST=obold_AST; 1601 } 1602 /*** 1603 */ 1604 public final void cbold() throws RecognitionException, 1605 TokenStreamException 1606 { 1607 returnAST=null; 1608 ASTPair currentAST=new ASTPair(); 1609 AST cbold_AST=null; 1610 try{ 1611 // for error handling 1612 AST tmp37_AST=null; 1613 tmp37_AST=astFactory.create(LT(1)); 1614 astFactory.makeASTRoot(currentAST, tmp37_AST); 1615 match(CBOLD); 1616 { 1617 _loop107: 1618 1619 do { 1620 if(LA(1)==WORD) { 1621 attr(); 1622 astFactory.addASTChild(currentAST, returnAST); 1623 } else { 1624 break _loop107; 1625 } 1626 } while(true); 1627 1628 } 1629 match(GT); 1630 cbold_AST=(AST)currentAST.root; 1631 }catch (RecognitionException ex) { 1632 reportError(ex); 1633 consume(); 1634 consumeUntil(_tokenSet_4); 1635 } 1636 returnAST=cbold_AST; 1637 } 1638 /*** 1639 */ 1640 public final void ounder() throws RecognitionException, 1641 TokenStreamException 1642 { 1643 returnAST=null; 1644 ASTPair currentAST=new ASTPair(); 1645 AST ounder_AST=null; 1646 try{ 1647 // for error handling 1648 AST tmp39_AST=null; 1649 tmp39_AST=astFactory.create(LT(1)); 1650 astFactory.makeASTRoot(currentAST, tmp39_AST); 1651 match(OUNDER); 1652 { 1653 _loop110: 1654 1655 do { 1656 if(LA(1)==WORD) { 1657 attr(); 1658 astFactory.addASTChild(currentAST, returnAST); 1659 } else { 1660 break _loop110; 1661 } 1662 } while(true); 1663 1664 } 1665 match(GT); 1666 ounder_AST=(AST)currentAST.root; 1667 }catch (RecognitionException ex) { 1668 reportError(ex); 1669 consume(); 1670 consumeUntil(_tokenSet_11); 1671 } 1672 returnAST=ounder_AST; 1673 } 1674 /*** 1675 */ 1676 public final void cunder() throws RecognitionException, 1677 TokenStreamException 1678 { 1679 returnAST=null; 1680 ASTPair currentAST=new ASTPair(); 1681 AST cunder_AST=null; 1682 try{ 1683 // for error handling 1684 AST tmp41_AST=null; 1685 tmp41_AST=astFactory.create(LT(1)); 1686 astFactory.makeASTRoot(currentAST, tmp41_AST); 1687 match(CUNDER); 1688 { 1689 _loop113: 1690 1691 do { 1692 if(LA(1)==WORD) { 1693 attr(); 1694 astFactory.addASTChild(currentAST, returnAST); 1695 } else { 1696 break _loop113; 1697 } 1698 } while(true); 1699 1700 } 1701 match(GT); 1702 cunder_AST=(AST)currentAST.root; 1703 }catch (RecognitionException ex) { 1704 reportError(ex); 1705 consume(); 1706 consumeUntil(_tokenSet_4); 1707 } 1708 returnAST=cunder_AST; 1709 } 1710 /*** 1711 */ 1712 public final void ocode() throws RecognitionException, 1713 TokenStreamException 1714 { 1715 returnAST=null; 1716 ASTPair currentAST=new ASTPair(); 1717 AST ocode_AST=null; 1718 try{ 1719 // for error handling 1720 AST tmp43_AST=null; 1721 tmp43_AST=astFactory.create(LT(1)); 1722 astFactory.makeASTRoot(currentAST, tmp43_AST); 1723 match(OCODE); 1724 { 1725 _loop86: 1726 1727 do { 1728 if(LA(1)==WORD) { 1729 attr(); 1730 astFactory.addASTChild(currentAST, returnAST); 1731 } else { 1732 break _loop86; 1733 } 1734 } while(true); 1735 1736 } 1737 match(GT); 1738 ocode_AST=(AST)currentAST.root; 1739 }catch (RecognitionException ex) { 1740 reportError(ex); 1741 consume(); 1742 consumeUntil(_tokenSet_12); 1743 } 1744 returnAST=ocode_AST; 1745 } 1746 /*** 1747 */ 1748 public final void ccode() throws RecognitionException, 1749 TokenStreamException 1750 { 1751 returnAST=null; 1752 ASTPair currentAST=new ASTPair(); 1753 AST ccode_AST=null; 1754 try{ 1755 // for error handling 1756 AST tmp45_AST=null; 1757 tmp45_AST=astFactory.create(LT(1)); 1758 astFactory.makeASTRoot(currentAST, tmp45_AST); 1759 match(CCODE); 1760 { 1761 _loop89: 1762 1763 do { 1764 if(LA(1)==WORD) { 1765 attr(); 1766 astFactory.addASTChild(currentAST, returnAST); 1767 } else { 1768 break _loop89; 1769 } 1770 } while(true); 1771 1772 } 1773 match(GT); 1774 ccode_AST=(AST)currentAST.root; 1775 }catch (RecognitionException ex) { 1776 reportError(ex); 1777 consume(); 1778 consumeUntil(_tokenSet_4); 1779 } 1780 returnAST=ccode_AST; 1781 } 1782 /*** 1783 */ 1784 public final void oanchor() throws RecognitionException, 1785 TokenStreamException 1786 { 1787 returnAST=null; 1788 ASTPair currentAST=new ASTPair(); 1789 AST oanchor_AST=null; 1790 try{ 1791 // for error handling 1792 AST tmp47_AST=null; 1793 tmp47_AST=astFactory.create(LT(1)); 1794 astFactory.makeASTRoot(currentAST, tmp47_AST); 1795 match(OANCHOR); 1796 { 1797 _loop92: 1798 1799 do { 1800 if(LA(1)==WORD) { 1801 attr(); 1802 astFactory.addASTChild(currentAST, returnAST); 1803 } else { 1804 break _loop92; 1805 } 1806 } while(true); 1807 1808 } 1809 match(GT); 1810 oanchor_AST=(AST)currentAST.root; 1811 }catch (RecognitionException ex) { 1812 reportError(ex); 1813 consume(); 1814 consumeUntil(_tokenSet_13); 1815 } 1816 returnAST=oanchor_AST; 1817 } 1818 /*** 1819 */ 1820 public final void canchor() throws RecognitionException, 1821 TokenStreamException 1822 { 1823 returnAST=null; 1824 ASTPair currentAST=new ASTPair(); 1825 AST canchor_AST=null; 1826 try{ 1827 // for error handling 1828 AST tmp49_AST=null; 1829 tmp49_AST=astFactory.create(LT(1)); 1830 astFactory.makeASTRoot(currentAST, tmp49_AST); 1831 match(CANCHOR); 1832 { 1833 _loop95: 1834 1835 do { 1836 if(LA(1)==WORD) { 1837 attr(); 1838 astFactory.addASTChild(currentAST, returnAST); 1839 } else { 1840 break _loop95; 1841 } 1842 } while(true); 1843 1844 } 1845 match(GT); 1846 canchor_AST=(AST)currentAST.root; 1847 }catch (RecognitionException ex) { 1848 reportError(ex); 1849 consume(); 1850 consumeUntil(_tokenSet_4); 1851 } 1852 returnAST=canchor_AST; 1853 } 1854 /*** 1855 */ 1856 public final void string() throws RecognitionException, 1857 TokenStreamException 1858 { 1859 returnAST=null; 1860 ASTPair currentAST=new ASTPair(); 1861 AST string_AST=null; 1862 Token od=null; 1863 AST od_AST=null; 1864 AST dd_AST=null; 1865 Token cd=null; 1866 AST cd_AST=null; 1867 Token os=null; 1868 AST os_AST=null; 1869 AST ds_AST=null; 1870 Token cs=null; 1871 AST cs_AST=null; 1872 try{ 1873 // for error handling 1874 switch(LA(1)) { 1875 case DQUOTE: 1876 1877 { 1878 od=LT(1); 1879 od_AST=astFactory.create(od); 1880 match(DQUOTE); 1881 string_data_d(); 1882 dd_AST=(AST)returnAST; 1883 cd=LT(1); 1884 cd_AST=astFactory.create(cd); 1885 match(DQUOTE); 1886 string_AST=(AST)currentAST.root; 1887 string_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(STRING, 1888 "STRING")).add(od_AST).add(dd_AST).add(cd_AST)); 1889 currentAST.root=string_AST; 1890 currentAST.child=((string_AST!=null&& 1891 string_AST.getFirstChild()!=null)?string_AST.getFirstChild():string_AST); 1892 currentAST.advanceChildToEnd(); 1893 break; 1894 } 1895 case SQUOTE: 1896 1897 { 1898 os=LT(1); 1899 os_AST=astFactory.create(os); 1900 match(SQUOTE); 1901 string_data_s(); 1902 ds_AST=(AST)returnAST; 1903 cs=LT(1); 1904 cs_AST=astFactory.create(cs); 1905 match(SQUOTE); 1906 string_AST=(AST)currentAST.root; 1907 string_AST=(AST)astFactory.make((new ASTArray(4)).add(astFactory.create(STRING, 1908 "STRING")).add(os_AST).add(ds_AST).add(cs_AST)); 1909 currentAST.root=string_AST; 1910 currentAST.child=((string_AST!=null&& 1911 string_AST.getFirstChild()!=null)?string_AST.getFirstChild():string_AST); 1912 currentAST.advanceChildToEnd(); 1913 break; 1914 } 1915 default: 1916 1917 { 1918 throw new NoViableAltException(LT(1), getFilename()); 1919 } 1920 } 1921 }catch (RecognitionException ex) { 1922 reportError(ex); 1923 consume(); 1924 consumeUntil(_tokenSet_4); 1925 } 1926 returnAST=string_AST; 1927 } 1928 /*** 1929 */ 1930 public final void string_data_d() throws RecognitionException, 1931 TokenStreamException 1932 { 1933 returnAST=null; 1934 ASTPair currentAST=new ASTPair(); 1935 AST string_data_d_AST=null; 1936 try{ 1937 // for error handling 1938 { 1939 _loop65: 1940 1941 do { 1942 switch(LA(1)) { 1943 case LITERAL_param: 1944 case LITERAL_return: 1945 case LITERAL_author: 1946 case WORD: 1947 case INT: 1948 case MINUS: 1949 case GT: 1950 case EQUAL: 1951 case OTHER_TOKEN: 1952 1953 { 1954 pcdata_no_quote(); 1955 astFactory.addASTChild(currentAST, 1956 returnAST); 1957 break; 1958 } 1959 case SQUOTE: 1960 1961 { 1962 AST tmp51_AST=null; 1963 tmp51_AST=astFactory.create(LT(1)); 1964 astFactory.addASTChild(currentAST, 1965 tmp51_AST); 1966 match(SQUOTE); 1967 break; 1968 } 1969 case AT: 1970 1971 { 1972 AST tmp52_AST=null; 1973 tmp52_AST=astFactory.create(LT(1)); 1974 astFactory.addASTChild(currentAST, 1975 tmp52_AST); 1976 match(AT); 1977 break; 1978 } 1979 default: 1980 1981 { 1982 break _loop65; 1983 } 1984 } 1985 } while(true); 1986 1987 } 1988 string_data_d_AST=(AST)currentAST.root; 1989 }catch (RecognitionException ex) { 1990 reportError(ex); 1991 consume(); 1992 consumeUntil(_tokenSet_14); 1993 } 1994 returnAST=string_data_d_AST; 1995 } 1996 /*** 1997 */ 1998 public final void string_data_s() throws RecognitionException, 1999 TokenStreamException 2000 { 2001 returnAST=null; 2002 ASTPair currentAST=new ASTPair(); 2003 AST string_data_s_AST=null; 2004 try{ 2005 // for error handling 2006 { 2007 _loop68: 2008 2009 do { 2010 switch(LA(1)) { 2011 case LITERAL_param: 2012 case LITERAL_return: 2013 case LITERAL_author: 2014 case WORD: 2015 case INT: 2016 case MINUS: 2017 case GT: 2018 case EQUAL: 2019 case OTHER_TOKEN: 2020 2021 { 2022 pcdata_no_quote(); 2023 astFactory.addASTChild(currentAST, 2024 returnAST); 2025 break; 2026 } 2027 case DQUOTE: 2028 2029 { 2030 AST tmp53_AST=null; 2031 tmp53_AST=astFactory.create(LT(1)); 2032 astFactory.addASTChild(currentAST, 2033 tmp53_AST); 2034 match(DQUOTE); 2035 break; 2036 } 2037 case AT: 2038 2039 { 2040 AST tmp54_AST=null; 2041 tmp54_AST=astFactory.create(LT(1)); 2042 astFactory.addASTChild(currentAST, 2043 tmp54_AST); 2044 match(AT); 2045 break; 2046 } 2047 default: 2048 2049 { 2050 break _loop68; 2051 } 2052 } 2053 } while(true); 2054 2055 } 2056 string_data_s_AST=(AST)currentAST.root; 2057 }catch (RecognitionException ex) { 2058 reportError(ex); 2059 consume(); 2060 consumeUntil(_tokenSet_15); 2061 } 2062 returnAST=string_data_s_AST; 2063 } 2064 public static final String[] _tokenNames={"<0>","EOF","<2>", 2065 "NULL_TREE_LOOKAHEAD","PARAGRAPH","PREFORMATTED","ITALIC","UNDERLINE", 2066 "BOLD","CODE","ANCHOR","ATTRIBUTE","STRING","JAVADOC","JTAG", 2067 "JTAG_AUTHOR","JTAG_PARAM","JTAG_RETURN","OJAVADOC","CJAVADOC","AT", 2068 "\"param\"","\"return\"","\"author\"","WORD","DQUOTE","SQUOTE","INT", 2069 "MINUS","GT","EQUAL","OTHER_TOKEN","OBR","OPARA","CPARA","OPRE","CPRE", 2070 "OCODE","CCODE","OANCHOR","CANCHOR","OITALIC","CITALIC","OBOLD", 2071 "CBOLD","OUNDER","CUNDER","COMMENT_DATA","COMMENT","WSCHARS","SPECIAL", 2072 "HEXINT","DIGIT","HEXDIGIT","LCLETTER","WS"}; 2073 /*** 2074 */ 2075 protected void buildTokenTypeASTClassMap() 2076 { 2077 tokenTypeToASTClassMap=null; 2078 } 2079 /*** 2080 * @return 2081 */ 2082 private static final long[] mk_tokenSet_0() 2083 { 2084 long[] data={2L,0L}; 2085 return data; 2086 } 2087 public static final BitSet _tokenSet_0=new BitSet(mk_tokenSet_0()); 2088 /*** 2089 * @return 2090 */ 2091 private static final long[] mk_tokenSet_1() 2092 { 2093 long[] data={524288L,0L}; 2094 return data; 2095 } 2096 public static final BitSet _tokenSet_1=new BitSet(mk_tokenSet_1()); 2097 /*** 2098 * @return 2099 */ 2100 private static final long[] mk_tokenSet_2() 2101 { 2102 long[] data={46918222217216L,0L}; 2103 return data; 2104 } 2105 public static final BitSet _tokenSet_2=new BitSet(mk_tokenSet_2()); 2106 /*** 2107 * @return 2108 */ 2109 private static final long[] mk_tokenSet_3() 2110 { 2111 long[] data={46875270971392L,0L}; 2112 return data; 2113 } 2114 public static final BitSet _tokenSet_3=new BitSet(mk_tokenSet_3()); 2115 /*** 2116 * @return 2117 */ 2118 private static final long[] mk_tokenSet_4() 2119 { 2120 long[] data={140737487831040L,0L}; 2121 return data; 2122 } 2123 public static final BitSet _tokenSet_4=new BitSet(mk_tokenSet_4()); 2124 /*** 2125 * @return 2126 */ 2127 private static final long[] mk_tokenSet_5() 2128 { 2129 long[] data={4192206848L,0L}; 2130 return data; 2131 } 2132 public static final BitSet _tokenSet_5=new BitSet(mk_tokenSet_5()); 2133 /*** 2134 * @return 2135 */ 2136 private static final long[] mk_tokenSet_6() 2137 { 2138 long[] data={140737487831042L,0L}; 2139 return data; 2140 } 2141 public static final BitSet _tokenSet_6=new BitSet(mk_tokenSet_6()); 2142 /*** 2143 * @return 2144 */ 2145 private static final long[] mk_tokenSet_7() 2146 { 2147 long[] data={46935402086400L,0L}; 2148 return data; 2149 } 2150 public static final BitSet _tokenSet_7=new BitSet(mk_tokenSet_7()); 2151 /*** 2152 * @return 2153 */ 2154 private static final long[] mk_tokenSet_8() 2155 { 2156 long[] data={46986941693952L,0L}; 2157 return data; 2158 } 2159 public static final BitSet _tokenSet_8=new BitSet(mk_tokenSet_8()); 2160 /*** 2161 * @return 2162 */ 2163 private static final long[] mk_tokenSet_9() 2164 { 2165 long[] data={51273317482496L,0L}; 2166 return data; 2167 } 2168 public static final BitSet _tokenSet_9=new BitSet(mk_tokenSet_9()); 2169 /*** 2170 * @return 2171 */ 2172 private static final long[] mk_tokenSet_10() 2173 { 2174 long[] data={64467457015808L,0L}; 2175 return data; 2176 } 2177 public static final BitSet _tokenSet_10=new BitSet(mk_tokenSet_10()); 2178 /*** 2179 * @return 2180 */ 2181 private static final long[] mk_tokenSet_11() 2182 { 2183 long[] data={117244015149056L,0L}; 2184 return data; 2185 } 2186 public static final BitSet _tokenSet_11=new BitSet(mk_tokenSet_11()); 2187 /*** 2188 * @return 2189 */ 2190 private static final long[] mk_tokenSet_12() 2191 { 2192 long[] data={47150148878336L,0L}; 2193 return data; 2194 } 2195 public static final BitSet _tokenSet_12=new BitSet(mk_tokenSet_12()); 2196 /*** 2197 * @return 2198 */ 2199 private static final long[] mk_tokenSet_13() 2200 { 2201 long[] data={47974782599168L,0L}; 2202 return data; 2203 } 2204 public static final BitSet _tokenSet_13=new BitSet(mk_tokenSet_13()); 2205 /*** 2206 * @return 2207 */ 2208 private static final long[] mk_tokenSet_14() 2209 { 2210 long[] data={33554432L,0L}; 2211 return data; 2212 } 2213 public static final BitSet _tokenSet_14=new BitSet(mk_tokenSet_14()); 2214 /*** 2215 * @return 2216 */ 2217 private static final long[] mk_tokenSet_15() 2218 { 2219 long[] data={67108864L,0L}; 2220 return data; 2221 } 2222 public static final BitSet _tokenSet_15=new BitSet(mk_tokenSet_15()); 2223 }

This page was automatically generated by Maven