1 11 12 package org.eclipse.jdt.core.dom; 13 14 104 public abstract class ASTVisitor { 105 106 110 private boolean visitDocTags; 111 112 121 public ASTVisitor() { 122 this(false); 123 } 124 125 134 public ASTVisitor(boolean visitDocTags) { 135 this.visitDocTags = visitDocTags; 136 } 137 138 147 public void preVisit(ASTNode node) { 148 } 150 151 160 public void postVisit(ASTNode node) { 161 } 163 164 165 178 public boolean visit(AnnotationTypeDeclaration node) { 179 return true; 180 } 181 182 183 196 public boolean visit(AnnotationTypeMemberDeclaration node) { 197 return true; 198 } 199 200 212 public boolean visit(AnonymousClassDeclaration node) { 213 return true; 214 } 215 216 228 public boolean visit(ArrayAccess node) { 229 return true; 230 } 231 232 244 public boolean visit(ArrayCreation node) { 245 return true; 246 } 247 248 260 public boolean visit(ArrayInitializer node) { 261 return true; 262 } 263 264 276 public boolean visit(ArrayType node) { 277 return true; 278 } 279 280 292 public boolean visit(AssertStatement node) { 293 return true; 294 } 295 296 308 public boolean visit(Assignment node) { 309 return true; 310 } 311 312 324 public boolean visit(Block node) { 325 return true; 326 } 327 328 329 347 public boolean visit(BlockComment node) { 348 return true; 349 } 350 351 363 public boolean visit(BooleanLiteral node) { 364 return true; 365 } 366 367 379 public boolean visit(BreakStatement node) { 380 return true; 381 } 382 383 395 public boolean visit(CastExpression node) { 396 return true; 397 } 398 399 411 public boolean visit(CatchClause node) { 412 return true; 413 } 414 415 427 public boolean visit(CharacterLiteral node) { 428 return true; 429 } 430 431 443 public boolean visit(ClassInstanceCreation node) { 444 return true; 445 } 446 447 459 public boolean visit(CompilationUnit node) { 460 return true; 461 } 462 463 475 public boolean visit(ConditionalExpression node) { 476 return true; 477 } 478 479 491 public boolean visit(ConstructorInvocation node) { 492 return true; 493 } 494 495 507 public boolean visit(ContinueStatement node) { 508 return true; 509 } 510 511 523 public boolean visit(DoStatement node) { 524 return true; 525 } 526 527 539 public boolean visit(EmptyStatement node) { 540 return true; 541 } 542 543 556 public boolean visit(EnhancedForStatement node) { 557 return true; 558 } 559 560 573 public boolean visit(EnumConstantDeclaration node) { 574 return true; 575 } 576 577 590 public boolean visit(EnumDeclaration node) { 591 return true; 592 } 593 594 606 public boolean visit(ExpressionStatement node) { 607 return true; 608 } 609 610 622 public boolean visit(FieldAccess node) { 623 return true; 624 } 625 626 638 public boolean visit(FieldDeclaration node) { 639 return true; 640 } 641 642 654 public boolean visit(ForStatement node) { 655 return true; 656 } 657 658 670 public boolean visit(IfStatement node) { 671 return true; 672 } 673 674 686 public boolean visit(ImportDeclaration node) { 687 return true; 688 } 689 690 702 public boolean visit(InfixExpression node) { 703 return true; 704 } 705 706 718 public boolean visit(InstanceofExpression node) { 719 return true; 720 } 721 722 734 public boolean visit(Initializer node) { 735 return true; 736 } 737 738 755 public boolean visit(Javadoc node) { 756 return this.visitDocTags; 758 } 759 760 772 public boolean visit(LabeledStatement node) { 773 return true; 774 } 775 776 777 795 public boolean visit(LineComment node) { 796 return true; 797 } 798 799 800 813 public boolean visit(MarkerAnnotation node) { 814 return true; 815 } 816 817 818 831 public boolean visit(MemberRef node) { 832 return true; 833 } 834 835 836 849 public boolean visit(MemberValuePair node) { 850 return true; 851 } 852 853 854 867 public boolean visit(MethodRef node) { 868 return true; 869 } 870 871 872 885 public boolean visit(MethodRefParameter node) { 886 return true; 887 } 888 889 890 902 public boolean visit(MethodDeclaration node) { 903 return true; 904 } 905 906 918 public boolean visit(MethodInvocation node) { 919 return true; 920 } 921 922 923 936 public boolean visit(Modifier node) { 937 return true; 938 } 939 940 941 954 public boolean visit(NormalAnnotation node) { 955 return true; 956 } 957 958 970 public boolean visit(NullLiteral node) { 971 return true; 972 } 973 974 986 public boolean visit(NumberLiteral node) { 987 return true; 988 } 989 990 1002 public boolean visit(PackageDeclaration node) { 1003 return true; 1004 } 1005 1006 1007 1020 public boolean visit(ParameterizedType node) { 1021 return true; 1022 } 1023 1024 1036 public boolean visit(ParenthesizedExpression node) { 1037 return true; 1038 } 1039 1040 1052 public boolean visit(PostfixExpression node) { 1053 return true; 1054 } 1055 1056 1068 public boolean visit(PrefixExpression node) { 1069 return true; 1070 } 1071 1072 1084 public boolean visit(PrimitiveType node) { 1085 return true; 1086 } 1087 1088 1100 public boolean visit(QualifiedName node) { 1101 return true; 1102 } 1103 1104 1117 public boolean visit(QualifiedType node) { 1118 return true; 1119 } 1120 1121 1133 public boolean visit(ReturnStatement node) { 1134 return true; 1135 } 1136 1137 1149 public boolean visit(SimpleName node) { 1150 return true; 1151 } 1152 1153 1165 public boolean visit(SimpleType node) { 1166 return true; 1167 } 1168 1169 1170 1183 public boolean visit(SingleMemberAnnotation node) { 1184 return true; 1185 } 1186 1187 1188 1200 public boolean visit(SingleVariableDeclaration node) { 1201 return true; 1202 } 1203 1204 1216 public boolean visit(StringLiteral node) { 1217 return true; 1218 } 1219 1220 1232 public boolean visit(SuperConstructorInvocation node) { 1233 return true; 1234 } 1235 1236 1248 public boolean visit(SuperFieldAccess node) { 1249 return true; 1250 } 1251 1252 1264 public boolean visit(SuperMethodInvocation node) { 1265 return true; 1266 } 1267 1268 1280 public boolean visit(SwitchCase node) { 1281 return true; 1282 } 1283 1284 1296 public boolean visit(SwitchStatement node) { 1297 return true; 1298 } 1299 1300 1312 public boolean visit(SynchronizedStatement node) { 1313 return true; 1314 } 1315 1316 1317 1330 public boolean visit(TagElement node) { 1331 return true; 1332 } 1333 1334 1335 1348 public boolean visit(TextElement node) { 1349 return true; 1350 } 1351 1352 1353 1365 public boolean visit(ThisExpression node) { 1366 return true; 1367 } 1368 1369 1381 public boolean visit(ThrowStatement node) { 1382 return true; 1383 } 1384 1385 1397 public boolean visit(TryStatement node) { 1398 return true; 1399 } 1400 1401 1413 public boolean visit(TypeDeclaration node) { 1414 return true; 1415 } 1416 1417 1429 public boolean visit(TypeDeclarationStatement node) { 1430 return true; 1431 } 1432 1433 1445 public boolean visit(TypeLiteral node) { 1446 return true; 1447 } 1448 1449 1462 public boolean visit(TypeParameter node) { 1463 return true; 1464 } 1465 1466 1478 public boolean visit(VariableDeclarationExpression node) { 1479 return true; 1480 } 1481 1482 1494 public boolean visit(VariableDeclarationStatement node) { 1495 return true; 1496 } 1497 1498 1510 public boolean visit(VariableDeclarationFragment node) { 1511 return true; 1512 } 1513 1514 1526 public boolean visit(WhileStatement node) { 1527 return true; 1528 } 1529 1530 1543 public boolean visit(WildcardType node) { 1544 return true; 1545 } 1546 1547 1556 public void endVisit(AnnotationTypeDeclaration node) { 1557 } 1559 1560 1569 public void endVisit(AnnotationTypeMemberDeclaration node) { 1570 } 1572 1573 1581 public void endVisit(AnonymousClassDeclaration node) { 1582 } 1584 1585 1593 public void endVisit(ArrayAccess node) { 1594 } 1596 1597 1605 public void endVisit(ArrayCreation node) { 1606 } 1608 1609 1617 public void endVisit(ArrayInitializer node) { 1618 } 1620 1621 1629 public void endVisit(ArrayType node) { 1630 } 1632 1633 1641 public void endVisit(AssertStatement node) { 1642 } 1644 1645 1653 public void endVisit(Assignment node) { 1654 } 1656 1657 1665 public void endVisit(Block node) { 1666 } 1668 1669 1683 public void endVisit(BlockComment node) { 1684 } 1686 1687 1695 public void endVisit(BooleanLiteral node) { 1696 } 1698 1699 1707 public void endVisit(BreakStatement node) { 1708 } 1710 1711 1719 public void endVisit(CastExpression node) { 1720 } 1722 1723 1731 public void endVisit(CatchClause node) { 1732 } 1734 1735 1743 public void endVisit(CharacterLiteral node) { 1744 } 1746 1747 1755 public void endVisit(ClassInstanceCreation node) { 1756 } 1758 1759 1767 public void endVisit(CompilationUnit node) { 1768 } 1770 1771 1779 public void endVisit(ConditionalExpression node) { 1780 } 1782 1783 1791 public void endVisit(ConstructorInvocation node) { 1792 } 1794 1795 1803 public void endVisit(ContinueStatement node) { 1804 } 1806 1807 1815 public void endVisit(DoStatement node) { 1816 } 1818 1819 1827 public void endVisit(EmptyStatement node) { 1828 } 1830 1831 1840 public void endVisit(EnhancedForStatement node) { 1841 } 1843 1844 1853 public void endVisit(EnumConstantDeclaration node) { 1854 } 1856 1857 1866 public void endVisit(EnumDeclaration node) { 1867 } 1869 1870 1878 public void endVisit(ExpressionStatement node) { 1879 } 1881 1882 1890 public void endVisit(FieldAccess node) { 1891 } 1893 1894 1902 public void endVisit(FieldDeclaration node) { 1903 } 1905 1906 1914 public void endVisit(ForStatement node) { 1915 } 1917 1918 1926 public void endVisit(IfStatement node) { 1927 } 1929 1930 1938 public void endVisit(ImportDeclaration node) { 1939 } 1941 1942 1950 public void endVisit(InfixExpression node) { 1951 } 1953 1954 1962 public void endVisit(InstanceofExpression node) { 1963 } 1965 1966 1974 public void endVisit(Initializer node) { 1975 } 1977 1978 1986 public void endVisit(Javadoc node) { 1987 } 1989 1990 1998 public void endVisit(LabeledStatement node) { 1999 } 2001 2002 2016 public void endVisit(LineComment node) { 2017 } 2019 2020 2029 public void endVisit(MarkerAnnotation node) { 2030 } 2032 2033 2042 public void endVisit(MemberRef node) { 2043 } 2045 2046 2055 public void endVisit(MemberValuePair node) { 2056 } 2058 2059 2068 public void endVisit(MethodRef node) { 2069 } 2071 2072 2081 public void endVisit(MethodRefParameter node) { 2082 } 2084 2085 2093 public void endVisit(MethodDeclaration node) { 2094 } 2096 2097 2105 public void endVisit(MethodInvocation node) { 2106 } 2108 2109 2118 public void endVisit(Modifier node) { 2119 } 2121 2122 2131 public void endVisit(NormalAnnotation node) { 2132 } 2134 2135 2143 public void endVisit(NullLiteral node) { 2144 } 2146 2147 2155 public void endVisit(NumberLiteral node) { 2156 } 2158 2159 2167 public void endVisit(PackageDeclaration node) { 2168 } 2170 2171 2180 public void endVisit(ParameterizedType node) { 2181 } 2183 2184 2192 public void endVisit(ParenthesizedExpression node) { 2193 } 2195 2196 2204 public void endVisit(PostfixExpression node) { 2205 } 2207 2208 2216 public void endVisit(PrefixExpression node) { 2217 } 2219 2220 2228 public void endVisit(PrimitiveType node) { 2229 } 2231 2232 2240 public void endVisit(QualifiedName node) { 2241 } 2243 2244 2253 public void endVisit(QualifiedType node) { 2254 } 2256 2257 2265 public void endVisit(ReturnStatement node) { 2266 } 2268 2269 2277 public void endVisit(SimpleName node) { 2278 } 2280 2281 2289 public void endVisit(SimpleType node) { 2290 } 2292 2293 2302 public void endVisit(SingleMemberAnnotation node) { 2303 } 2305 2306 2314 public void endVisit(SingleVariableDeclaration node) { 2315 } 2317 2318 2326 public void endVisit(StringLiteral node) { 2327 } 2329 2330 2338 public void endVisit(SuperConstructorInvocation node) { 2339 } 2341 2342 2350 public void endVisit(SuperFieldAccess node) { 2351 } 2353 2354 2362 public void endVisit(SuperMethodInvocation node) { 2363 } 2365 2366 2374 public void endVisit(SwitchCase node) { 2375 } 2377 2378 2386 public void endVisit(SwitchStatement node) { 2387 } 2389 2390 2398 public void endVisit(SynchronizedStatement node) { 2399 } 2401 2402 2411 public void endVisit(TagElement node) { 2412 } 2414 2415 2424 public void endVisit(TextElement node) { 2425 } 2427 2428 2436 public void endVisit(ThisExpression node) { 2437 } 2439 2440 2448 public void endVisit(ThrowStatement node) { 2449 } 2451 2452 2460 public void endVisit(TryStatement node) { 2461 } 2463 2464 2472 public void endVisit(TypeDeclaration node) { 2473 } 2475 2476 2484 public void endVisit(TypeDeclarationStatement node) { 2485 } 2487 2488 2496 public void endVisit(TypeLiteral node) { 2497 } 2499 2500 2509 public void endVisit(TypeParameter node) { 2510 } 2512 2513 2521 public void endVisit(VariableDeclarationExpression node) { 2522 } 2524 2525 2533 public void endVisit(VariableDeclarationStatement node) { 2534 } 2536 2537 2545 public void endVisit(VariableDeclarationFragment node) { 2546 } 2548 2549 2557 public void endVisit(WhileStatement node) { 2558 } 2560 2561 2570 public void endVisit(WildcardType node) { 2571 } 2573} 2574 | Popular Tags |