1 /*******************************************************************************
2  * Copyright (c) 2000, 2004 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Common Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/cpl-v10.html
7  *
8  * Contributors:
9  *     IBM Corporation - initial API and implementation
10  *******************************************************************************/
11 package net.sourceforge.phpdt.internal.compiler;
12 
13 import net.sourceforge.phpdt.core.compiler.IProblem;
14 import net.sourceforge.phpdt.internal.compiler.ast.AND_AND_Expression;
15 import net.sourceforge.phpdt.internal.compiler.ast.AllocationExpression;
16 import net.sourceforge.phpdt.internal.compiler.ast.Argument;
17 import net.sourceforge.phpdt.internal.compiler.ast.ArrayAllocationExpression;
18 import net.sourceforge.phpdt.internal.compiler.ast.ArrayInitializer;
19 import net.sourceforge.phpdt.internal.compiler.ast.ArrayQualifiedTypeReference;
20 import net.sourceforge.phpdt.internal.compiler.ast.ArrayReference;
21 import net.sourceforge.phpdt.internal.compiler.ast.ArrayTypeReference;
22 import net.sourceforge.phpdt.internal.compiler.ast.AssertStatement;
23 import net.sourceforge.phpdt.internal.compiler.ast.Assignment;
24 import net.sourceforge.phpdt.internal.compiler.ast.BinaryExpression;
25 import net.sourceforge.phpdt.internal.compiler.ast.Block;
26 import net.sourceforge.phpdt.internal.compiler.ast.BreakStatement;
27 import net.sourceforge.phpdt.internal.compiler.ast.CaseStatement;
28 import net.sourceforge.phpdt.internal.compiler.ast.CastExpression;
29 import net.sourceforge.phpdt.internal.compiler.ast.Clinit;
30 import net.sourceforge.phpdt.internal.compiler.ast.CompilationUnitDeclaration;
31 import net.sourceforge.phpdt.internal.compiler.ast.CompoundAssignment;
32 import net.sourceforge.phpdt.internal.compiler.ast.ConditionalExpression;
33 import net.sourceforge.phpdt.internal.compiler.ast.ConstructorDeclaration;
34 import net.sourceforge.phpdt.internal.compiler.ast.ContinueStatement;
35 import net.sourceforge.phpdt.internal.compiler.ast.DoStatement;
36 import net.sourceforge.phpdt.internal.compiler.ast.DoubleLiteral;
37 import net.sourceforge.phpdt.internal.compiler.ast.EmptyStatement;
38 import net.sourceforge.phpdt.internal.compiler.ast.EqualExpression;
39 import net.sourceforge.phpdt.internal.compiler.ast.ExplicitConstructorCall;
40 import net.sourceforge.phpdt.internal.compiler.ast.ExtendedStringLiteral;
41 import net.sourceforge.phpdt.internal.compiler.ast.FalseLiteral;
42 import net.sourceforge.phpdt.internal.compiler.ast.FieldDeclaration;
43 import net.sourceforge.phpdt.internal.compiler.ast.FieldReference;
44 import net.sourceforge.phpdt.internal.compiler.ast.FloatLiteral;
45 import net.sourceforge.phpdt.internal.compiler.ast.ForStatement;
46 import net.sourceforge.phpdt.internal.compiler.ast.IfStatement;
47 import net.sourceforge.phpdt.internal.compiler.ast.ImportReference;
48 import net.sourceforge.phpdt.internal.compiler.ast.Initializer;
49 import net.sourceforge.phpdt.internal.compiler.ast.InstanceOfExpression;
50 import net.sourceforge.phpdt.internal.compiler.ast.IntLiteral;
51 import net.sourceforge.phpdt.internal.compiler.ast.LabeledStatement;
52 import net.sourceforge.phpdt.internal.compiler.ast.LocalDeclaration;
53 import net.sourceforge.phpdt.internal.compiler.ast.LongLiteral;
54 import net.sourceforge.phpdt.internal.compiler.ast.MessageSend;
55 import net.sourceforge.phpdt.internal.compiler.ast.MethodDeclaration;
56 import net.sourceforge.phpdt.internal.compiler.ast.NullLiteral;
57 import net.sourceforge.phpdt.internal.compiler.ast.OR_OR_Expression;
58 import net.sourceforge.phpdt.internal.compiler.ast.PostfixExpression;
59 import net.sourceforge.phpdt.internal.compiler.ast.PrefixExpression;
60 import net.sourceforge.phpdt.internal.compiler.ast.QualifiedAllocationExpression;
61 import net.sourceforge.phpdt.internal.compiler.ast.QualifiedNameReference;
62 import net.sourceforge.phpdt.internal.compiler.ast.QualifiedSuperReference;
63 import net.sourceforge.phpdt.internal.compiler.ast.QualifiedThisReference;
64 import net.sourceforge.phpdt.internal.compiler.ast.QualifiedTypeReference;
65 import net.sourceforge.phpdt.internal.compiler.ast.ReturnStatement;
66 import net.sourceforge.phpdt.internal.compiler.ast.SingleNameReference;
67 import net.sourceforge.phpdt.internal.compiler.ast.SingleTypeReference;
68 import net.sourceforge.phpdt.internal.compiler.ast.StringLiteral;
69 import net.sourceforge.phpdt.internal.compiler.ast.SuperReference;
70 import net.sourceforge.phpdt.internal.compiler.ast.SwitchStatement;
71 import net.sourceforge.phpdt.internal.compiler.ast.ThisReference;
72 import net.sourceforge.phpdt.internal.compiler.ast.ThrowStatement;
73 import net.sourceforge.phpdt.internal.compiler.ast.TrueLiteral;
74 import net.sourceforge.phpdt.internal.compiler.ast.TryStatement;
75 import net.sourceforge.phpdt.internal.compiler.ast.TypeDeclaration;
76 import net.sourceforge.phpdt.internal.compiler.ast.UnaryExpression;
77 import net.sourceforge.phpdt.internal.compiler.ast.WhileStatement;
78 import net.sourceforge.phpdt.internal.compiler.lookup.BlockScope;
79 import net.sourceforge.phpdt.internal.compiler.lookup.ClassScope;
80 import net.sourceforge.phpdt.internal.compiler.lookup.CompilationUnitScope;
81 import net.sourceforge.phpdt.internal.compiler.lookup.MethodScope;
82 
83 /**
84  * A visitor for iterating through the parse tree.
85  */
86 public abstract class ASTVisitor {
87 
acceptProblem(IProblem problem)88 	public void acceptProblem(IProblem problem) {
89 		// do nothing by default
90 	}
91 
endVisit(AllocationExpression allocationExpression, BlockScope scope)92 	public void endVisit(AllocationExpression allocationExpression,
93 			BlockScope scope) {
94 		// do nothing by default
95 	}
96 
endVisit(AND_AND_Expression and_and_Expression, BlockScope scope)97 	public void endVisit(AND_AND_Expression and_and_Expression, BlockScope scope) {
98 		// do nothing by default
99 	}
100 
101 	// public void endVisit(JavadocArrayQualifiedTypeReference typeRef,
102 	// BlockScope scope) {
103 	// // do nothing by default
104 	// }
105 	// public void endVisit(JavadocArraySingleTypeReference typeRef, BlockScope
106 	// scope) {
107 	// // do nothing by default
108 	// }
109 	// public void endVisit(JavadocArgumentExpression expression, BlockScope
110 	// scope) {
111 	// // do nothing by default
112 	// }
113 	// public void endVisit(JavadocFieldReference fieldRef, BlockScope scope) {
114 	// // do nothing by default
115 	// }
116 	// public void endVisit(JavadocMessageSend messageSend, BlockScope scope) {
117 	// // do nothing by default
118 	// }
119 	// public void endVisit(JavadocQualifiedTypeReference typeRef, BlockScope
120 	// scope) {
121 	// // do nothing by default
122 	// }
123 	// public void endVisit(JavadocReturnStatement statement, BlockScope scope)
124 	// {
125 	// // do nothing by default
126 	// }
127 	// public void endVisit(JavadocSingleNameReference argument, BlockScope
128 	// scope) {
129 	// // do nothing by default
130 	// }
131 	// public void endVisit(JavadocSingleTypeReference typeRef, BlockScope
132 	// scope) {
133 	// // do nothing by default
134 	// }
endVisit(Argument argument, BlockScope scope)135 	public void endVisit(Argument argument, BlockScope scope) {
136 		// do nothing by default
137 	}
138 
endVisit(ArrayAllocationExpression arrayAllocationExpression, BlockScope scope)139 	public void endVisit(ArrayAllocationExpression arrayAllocationExpression,
140 			BlockScope scope) {
141 		// do nothing by default
142 	}
143 
endVisit(ArrayInitializer arrayInitializer, BlockScope scope)144 	public void endVisit(ArrayInitializer arrayInitializer, BlockScope scope) {
145 		// do nothing by default
146 	}
147 
endVisit( ArrayQualifiedTypeReference arrayQualifiedTypeReference, BlockScope scope)148 	public void endVisit(
149 			ArrayQualifiedTypeReference arrayQualifiedTypeReference,
150 			BlockScope scope) {
151 		// do nothing by default
152 	}
153 
endVisit( ArrayQualifiedTypeReference arrayQualifiedTypeReference, ClassScope scope)154 	public void endVisit(
155 			ArrayQualifiedTypeReference arrayQualifiedTypeReference,
156 			ClassScope scope) {
157 		// do nothing by default
158 	}
159 
endVisit(ArrayReference arrayReference, BlockScope scope)160 	public void endVisit(ArrayReference arrayReference, BlockScope scope) {
161 		// do nothing by default
162 	}
163 
endVisit(ArrayTypeReference arrayTypeReference, BlockScope scope)164 	public void endVisit(ArrayTypeReference arrayTypeReference, BlockScope scope) {
165 		// do nothing by default
166 	}
167 
endVisit(ArrayTypeReference arrayTypeReference, ClassScope scope)168 	public void endVisit(ArrayTypeReference arrayTypeReference, ClassScope scope) {
169 		// do nothing by default
170 	}
171 
endVisit(Assignment assignment, BlockScope scope)172 	public void endVisit(Assignment assignment, BlockScope scope) {
173 		// do nothing by default
174 	}
175 
endVisit(AssertStatement assertStatement, BlockScope scope)176 	public void endVisit(AssertStatement assertStatement, BlockScope scope) {
177 		// do nothing by default
178 	}
179 
endVisit(BinaryExpression binaryExpression, BlockScope scope)180 	public void endVisit(BinaryExpression binaryExpression, BlockScope scope) {
181 		// do nothing by default
182 	}
183 
endVisit(Block block, BlockScope scope)184 	public void endVisit(Block block, BlockScope scope) {
185 		// do nothing by default
186 	}
187 
endVisit(BreakStatement breakStatement, BlockScope scope)188 	public void endVisit(BreakStatement breakStatement, BlockScope scope) {
189 		// do nothing by default
190 	}
191 
endVisit(CaseStatement caseStatement, BlockScope scope)192 	public void endVisit(CaseStatement caseStatement, BlockScope scope) {
193 		// do nothing by default
194 	}
195 
endVisit(CastExpression castExpression, BlockScope scope)196 	public void endVisit(CastExpression castExpression, BlockScope scope) {
197 		// do nothing by default
198 	}
199 
endVisit(Clinit clinit, ClassScope scope)200 	public void endVisit(Clinit clinit, ClassScope scope) {
201 		// do nothing by default
202 	}
203 
endVisit(CompilationUnitDeclaration compilationUnitDeclaration, CompilationUnitScope scope)204 	public void endVisit(CompilationUnitDeclaration compilationUnitDeclaration,
205 			CompilationUnitScope scope) {
206 		// do nothing by default
207 	}
208 
endVisit(CompoundAssignment compoundAssignment, BlockScope scope)209 	public void endVisit(CompoundAssignment compoundAssignment, BlockScope scope) {
210 		// do nothing by default
211 	}
212 
endVisit(ConditionalExpression conditionalExpression, BlockScope scope)213 	public void endVisit(ConditionalExpression conditionalExpression,
214 			BlockScope scope) {
215 		// do nothing by default
216 	}
217 
endVisit(ConstructorDeclaration constructorDeclaration, ClassScope scope)218 	public void endVisit(ConstructorDeclaration constructorDeclaration,
219 			ClassScope scope) {
220 		// do nothing by default
221 	}
222 
endVisit(ContinueStatement continueStatement, BlockScope scope)223 	public void endVisit(ContinueStatement continueStatement, BlockScope scope) {
224 		// do nothing by default
225 	}
226 
endVisit(DoStatement doStatement, BlockScope scope)227 	public void endVisit(DoStatement doStatement, BlockScope scope) {
228 		// do nothing by default
229 	}
230 
endVisit(DoubleLiteral doubleLiteral, BlockScope scope)231 	public void endVisit(DoubleLiteral doubleLiteral, BlockScope scope) {
232 		// do nothing by default
233 	}
234 
endVisit(EqualExpression equalExpression, BlockScope scope)235 	public void endVisit(EqualExpression equalExpression, BlockScope scope) {
236 		// do nothing by default
237 	}
238 
endVisit(ExplicitConstructorCall explicitConstructor, BlockScope scope)239 	public void endVisit(ExplicitConstructorCall explicitConstructor,
240 			BlockScope scope) {
241 		// do nothing by default
242 	}
243 
endVisit(ExtendedStringLiteral extendedStringLiteral, BlockScope scope)244 	public void endVisit(ExtendedStringLiteral extendedStringLiteral,
245 			BlockScope scope) {
246 		// do nothing by default
247 	}
248 
endVisit(FalseLiteral falseLiteral, BlockScope scope)249 	public void endVisit(FalseLiteral falseLiteral, BlockScope scope) {
250 		// do nothing by default
251 	}
252 
endVisit(FieldDeclaration fieldDeclaration, MethodScope scope)253 	public void endVisit(FieldDeclaration fieldDeclaration, MethodScope scope) {
254 		// do nothing by default
255 	}
256 
endVisit(FieldReference fieldReference, BlockScope scope)257 	public void endVisit(FieldReference fieldReference, BlockScope scope) {
258 		// do nothing by default
259 	}
260 
endVisit(FloatLiteral floatLiteral, BlockScope scope)261 	public void endVisit(FloatLiteral floatLiteral, BlockScope scope) {
262 		// do nothing by default
263 	}
264 
endVisit(EmptyStatement emptyStatement, BlockScope scope)265 	public void endVisit(EmptyStatement emptyStatement, BlockScope scope) {
266 		// do nothing by default
267 	}
268 
endVisit(ForStatement forStatement, BlockScope scope)269 	public void endVisit(ForStatement forStatement, BlockScope scope) {
270 		// do nothing by default
271 	}
272 
endVisit(IfStatement ifStatement, BlockScope scope)273 	public void endVisit(IfStatement ifStatement, BlockScope scope) {
274 		// do nothing by default
275 	}
276 
endVisit(ImportReference importRef, CompilationUnitScope scope)277 	public void endVisit(ImportReference importRef, CompilationUnitScope scope) {
278 		// do nothing by default
279 	}
280 
endVisit(Initializer initializer, MethodScope scope)281 	public void endVisit(Initializer initializer, MethodScope scope) {
282 		// do nothing by default
283 	}
284 
endVisit(InstanceOfExpression instanceOfExpression, BlockScope scope)285 	public void endVisit(InstanceOfExpression instanceOfExpression,
286 			BlockScope scope) {
287 		// do nothing by default
288 	}
289 
endVisit(IntLiteral intLiteral, BlockScope scope)290 	public void endVisit(IntLiteral intLiteral, BlockScope scope) {
291 		// do nothing by default
292 	}
293 
endVisit(LabeledStatement labeledStatement, BlockScope scope)294 	public void endVisit(LabeledStatement labeledStatement, BlockScope scope) {
295 		// do nothing by default
296 	}
297 
endVisit(LocalDeclaration localDeclaration, BlockScope scope)298 	public void endVisit(LocalDeclaration localDeclaration, BlockScope scope) {
299 		// do nothing by default
300 	}
301 
endVisit(LongLiteral longLiteral, BlockScope scope)302 	public void endVisit(LongLiteral longLiteral, BlockScope scope) {
303 		// do nothing by default
304 	}
305 
endVisit(MessageSend messageSend, BlockScope scope)306 	public void endVisit(MessageSend messageSend, BlockScope scope) {
307 		// do nothing by default
308 	}
309 
endVisit(MethodDeclaration methodDeclaration, ClassScope scope)310 	public void endVisit(MethodDeclaration methodDeclaration, ClassScope scope) {
311 		// do nothing by default
312 	}
313 
314 	// public void endVisit(StringLiteralConcatenation literal, BlockScope
315 	// scope) {
316 	// // do nothing by default
317 	// }
endVisit(NullLiteral nullLiteral, BlockScope scope)318 	public void endVisit(NullLiteral nullLiteral, BlockScope scope) {
319 		// do nothing by default
320 	}
321 
endVisit(OR_OR_Expression or_or_Expression, BlockScope scope)322 	public void endVisit(OR_OR_Expression or_or_Expression, BlockScope scope) {
323 		// do nothing by default
324 	}
325 
endVisit(PostfixExpression postfixExpression, BlockScope scope)326 	public void endVisit(PostfixExpression postfixExpression, BlockScope scope) {
327 		// do nothing by default
328 	}
329 
endVisit(PrefixExpression prefixExpression, BlockScope scope)330 	public void endVisit(PrefixExpression prefixExpression, BlockScope scope) {
331 		// do nothing by default
332 	}
333 
endVisit( QualifiedAllocationExpression qualifiedAllocationExpression, BlockScope scope)334 	public void endVisit(
335 			QualifiedAllocationExpression qualifiedAllocationExpression,
336 			BlockScope scope) {
337 		// do nothing by default
338 	}
339 
endVisit(QualifiedNameReference qualifiedNameReference, BlockScope scope)340 	public void endVisit(QualifiedNameReference qualifiedNameReference,
341 			BlockScope scope) {
342 		// do nothing by default
343 	}
344 
endVisit(QualifiedSuperReference qualifiedSuperReference, BlockScope scope)345 	public void endVisit(QualifiedSuperReference qualifiedSuperReference,
346 			BlockScope scope) {
347 		// do nothing by default
348 	}
349 
endVisit(QualifiedThisReference qualifiedThisReference, BlockScope scope)350 	public void endVisit(QualifiedThisReference qualifiedThisReference,
351 			BlockScope scope) {
352 		// do nothing by default
353 	}
354 
endVisit(QualifiedTypeReference qualifiedTypeReference, BlockScope scope)355 	public void endVisit(QualifiedTypeReference qualifiedTypeReference,
356 			BlockScope scope) {
357 		// do nothing by default
358 	}
359 
endVisit(QualifiedTypeReference qualifiedTypeReference, ClassScope scope)360 	public void endVisit(QualifiedTypeReference qualifiedTypeReference,
361 			ClassScope scope) {
362 		// do nothing by default
363 	}
364 
endVisit(ReturnStatement returnStatement, BlockScope scope)365 	public void endVisit(ReturnStatement returnStatement, BlockScope scope) {
366 		// do nothing by default
367 	}
368 
endVisit(SingleNameReference singleNameReference, BlockScope scope)369 	public void endVisit(SingleNameReference singleNameReference,
370 			BlockScope scope) {
371 		// do nothing by default
372 	}
373 
endVisit(SingleTypeReference singleTypeReference, BlockScope scope)374 	public void endVisit(SingleTypeReference singleTypeReference,
375 			BlockScope scope) {
376 		// do nothing by default
377 	}
378 
endVisit(SingleTypeReference singleTypeReference, ClassScope scope)379 	public void endVisit(SingleTypeReference singleTypeReference,
380 			ClassScope scope) {
381 		// do nothing by default
382 	}
383 
endVisit(StringLiteral stringLiteral, BlockScope scope)384 	public void endVisit(StringLiteral stringLiteral, BlockScope scope) {
385 		// do nothing by default
386 	}
387 
endVisit(SuperReference superReference, BlockScope scope)388 	public void endVisit(SuperReference superReference, BlockScope scope) {
389 		// do nothing by default
390 	}
391 
endVisit(SwitchStatement switchStatement, BlockScope scope)392 	public void endVisit(SwitchStatement switchStatement, BlockScope scope) {
393 		// do nothing by default
394 	}
395 
endVisit(ThisReference thisReference, BlockScope scope)396 	public void endVisit(ThisReference thisReference, BlockScope scope) {
397 		// do nothing by default
398 	}
399 
endVisit(ThrowStatement throwStatement, BlockScope scope)400 	public void endVisit(ThrowStatement throwStatement, BlockScope scope) {
401 		// do nothing by default
402 	}
403 
endVisit(TrueLiteral trueLiteral, BlockScope scope)404 	public void endVisit(TrueLiteral trueLiteral, BlockScope scope) {
405 		// do nothing by default
406 	}
407 
endVisit(TryStatement tryStatement, BlockScope scope)408 	public void endVisit(TryStatement tryStatement, BlockScope scope) {
409 		// do nothing by default
410 	}
411 
endVisit(TypeDeclaration localTypeDeclaration, BlockScope scope)412 	public void endVisit(TypeDeclaration localTypeDeclaration, BlockScope scope) {
413 		// do nothing by default
414 	}
415 
endVisit(TypeDeclaration memberTypeDeclaration, ClassScope scope)416 	public void endVisit(TypeDeclaration memberTypeDeclaration, ClassScope scope) {
417 		// do nothing by default
418 	}
419 
endVisit(TypeDeclaration typeDeclaration, CompilationUnitScope scope)420 	public void endVisit(TypeDeclaration typeDeclaration,
421 			CompilationUnitScope scope) {
422 		// do nothing by default
423 	}
424 
endVisit(UnaryExpression unaryExpression, BlockScope scope)425 	public void endVisit(UnaryExpression unaryExpression, BlockScope scope) {
426 		// do nothing by default
427 	}
428 
endVisit(WhileStatement whileStatement, BlockScope scope)429 	public void endVisit(WhileStatement whileStatement, BlockScope scope) {
430 		// do nothing by default
431 	}
432 
visit(AllocationExpression allocationExpression, BlockScope scope)433 	public boolean visit(AllocationExpression allocationExpression,
434 			BlockScope scope) {
435 		return true; // do nothing by default, keep traversing
436 		// do nothing by default
437 	}
438 
visit(AND_AND_Expression and_and_Expression, BlockScope scope)439 	public boolean visit(AND_AND_Expression and_and_Expression, BlockScope scope) {
440 		return true; // do nothing by default, keep traversing
441 	}
442 
443 	// public boolean visit(JavadocArrayQualifiedTypeReference typeRef,
444 	// BlockScope scope) {
445 	// return true; // do nothing by default, keep traversing
446 	// }
447 	// public boolean visit(JavadocArraySingleTypeReference typeRef, BlockScope
448 	// scope) {
449 	// return true; // do nothing by default, keep traversing
450 	// }
451 	// public boolean visit(JavadocArgumentExpression expression, BlockScope
452 	// scope) {
453 	// return true; // do nothing by default, keep traversing
454 	// }
455 	// public boolean visit(JavadocFieldReference fieldRef, BlockScope scope) {
456 	// return true; // do nothing by default, keep traversing
457 	// }
458 	// public boolean visit(JavadocMessageSend messageSend, BlockScope scope) {
459 	// return true; // do nothing by default, keep traversing
460 	// }
461 	// public boolean visit(JavadocQualifiedTypeReference typeRef, BlockScope
462 	// scope) {
463 	// return true; // do nothing by default, keep traversing
464 	// }
465 	// public boolean visit(JavadocReturnStatement statement, BlockScope scope)
466 	// {
467 	// return true; // do nothing by default, keep traversing
468 	// }
469 	// public boolean visit(JavadocSingleNameReference argument, BlockScope
470 	// scope) {
471 	// return true; // do nothing by default, keep traversing
472 	// }
473 	// public boolean visit(JavadocSingleTypeReference typeRef, BlockScope
474 	// scope) {
475 	// return true; // do nothing by default, keep traversing
476 	// }
visit(Argument argument, BlockScope scope)477 	public boolean visit(Argument argument, BlockScope scope) {
478 		return true; // do nothing by default, keep traversing
479 	}
480 
visit(ArrayAllocationExpression arrayAllocationExpression, BlockScope scope)481 	public boolean visit(ArrayAllocationExpression arrayAllocationExpression,
482 			BlockScope scope) {
483 		return true; // do nothing by default, keep traversing
484 	}
485 
visit(ArrayInitializer arrayInitializer, BlockScope scope)486 	public boolean visit(ArrayInitializer arrayInitializer, BlockScope scope) {
487 		return true; // do nothing by default, keep traversing
488 	}
489 
visit( ArrayQualifiedTypeReference arrayQualifiedTypeReference, BlockScope scope)490 	public boolean visit(
491 			ArrayQualifiedTypeReference arrayQualifiedTypeReference,
492 			BlockScope scope) {
493 		return true; // do nothing by default, keep traversing
494 	}
495 
visit( ArrayQualifiedTypeReference arrayQualifiedTypeReference, ClassScope scope)496 	public boolean visit(
497 			ArrayQualifiedTypeReference arrayQualifiedTypeReference,
498 			ClassScope scope) {
499 		return true; // do nothing by default, keep traversing
500 	}
501 
visit(ArrayReference arrayReference, BlockScope scope)502 	public boolean visit(ArrayReference arrayReference, BlockScope scope) {
503 		return true; // do nothing by default, keep traversing
504 	}
505 
visit(ArrayTypeReference arrayTypeReference, BlockScope scope)506 	public boolean visit(ArrayTypeReference arrayTypeReference, BlockScope scope) {
507 		return true; // do nothing by default, keep traversing
508 	}
509 
visit(ArrayTypeReference arrayTypeReference, ClassScope scope)510 	public boolean visit(ArrayTypeReference arrayTypeReference, ClassScope scope) {
511 		return true; // do nothing by default, keep traversing
512 	}
513 
visit(Assignment assignment, BlockScope scope)514 	public boolean visit(Assignment assignment, BlockScope scope) {
515 		return true; // do nothing by default, keep traversing
516 	}
517 
visit(AssertStatement assertStatement, BlockScope scope)518 	public boolean visit(AssertStatement assertStatement, BlockScope scope) {
519 		return true; // do nothing by default, keep traversing
520 	}
521 
visit(BinaryExpression binaryExpression, BlockScope scope)522 	public boolean visit(BinaryExpression binaryExpression, BlockScope scope) {
523 		return true; // do nothing by default, keep traversing
524 	}
525 
visit(Block block, BlockScope scope)526 	public boolean visit(Block block, BlockScope scope) {
527 		return true; // do nothing by default, keep traversing
528 	}
529 
visit(BreakStatement breakStatement, BlockScope scope)530 	public boolean visit(BreakStatement breakStatement, BlockScope scope) {
531 		return true; // do nothing by default, keep traversing
532 	}
533 
visit(CaseStatement caseStatement, BlockScope scope)534 	public boolean visit(CaseStatement caseStatement, BlockScope scope) {
535 		return true; // do nothing by default, keep traversing
536 	}
537 
visit(CastExpression castExpression, BlockScope scope)538 	public boolean visit(CastExpression castExpression, BlockScope scope) {
539 		return true; // do nothing by default, keep traversing
540 	}
541 
visit(Clinit clinit, ClassScope scope)542 	public boolean visit(Clinit clinit, ClassScope scope) {
543 		return true; // do nothing by default, keep traversing
544 	}
545 
visit(CompilationUnitDeclaration compilationUnitDeclaration, CompilationUnitScope scope)546 	public boolean visit(CompilationUnitDeclaration compilationUnitDeclaration,
547 			CompilationUnitScope scope) {
548 		return true; // do nothing by default, keep traversing
549 	}
550 
visit(CompoundAssignment compoundAssignment, BlockScope scope)551 	public boolean visit(CompoundAssignment compoundAssignment, BlockScope scope) {
552 		return true; // do nothing by default, keep traversing
553 	}
554 
visit(ConditionalExpression conditionalExpression, BlockScope scope)555 	public boolean visit(ConditionalExpression conditionalExpression,
556 			BlockScope scope) {
557 		return true; // do nothing by default, keep traversing
558 	}
559 
visit(ConstructorDeclaration constructorDeclaration, ClassScope scope)560 	public boolean visit(ConstructorDeclaration constructorDeclaration,
561 			ClassScope scope) {
562 		return true; // do nothing by default, keep traversing
563 	}
564 
visit(ContinueStatement continueStatement, BlockScope scope)565 	public boolean visit(ContinueStatement continueStatement, BlockScope scope) {
566 		return true; // do nothing by default, keep traversing
567 	}
568 
visit(DoStatement doStatement, BlockScope scope)569 	public boolean visit(DoStatement doStatement, BlockScope scope) {
570 		return true; // do nothing by default, keep traversing
571 	}
572 
visit(DoubleLiteral doubleLiteral, BlockScope scope)573 	public boolean visit(DoubleLiteral doubleLiteral, BlockScope scope) {
574 		return true; // do nothing by default, keep traversing
575 	}
576 
visit(EqualExpression equalExpression, BlockScope scope)577 	public boolean visit(EqualExpression equalExpression, BlockScope scope) {
578 		return true; // do nothing by default, keep traversing
579 	}
580 
visit(EmptyStatement emptyStatement, BlockScope scope)581 	public boolean visit(EmptyStatement emptyStatement, BlockScope scope) {
582 		return true; // do nothing by default, keep traversing
583 	}
584 
visit(ExplicitConstructorCall explicitConstructor, BlockScope scope)585 	public boolean visit(ExplicitConstructorCall explicitConstructor,
586 			BlockScope scope) {
587 		return true; // do nothing by default, keep traversing
588 	}
589 
visit(ExtendedStringLiteral extendedStringLiteral, BlockScope scope)590 	public boolean visit(ExtendedStringLiteral extendedStringLiteral,
591 			BlockScope scope) {
592 		return true; // do nothing by default, keep traversing
593 	}
594 
visit(FalseLiteral falseLiteral, BlockScope scope)595 	public boolean visit(FalseLiteral falseLiteral, BlockScope scope) {
596 		return true; // do nothing by default, keep traversing
597 	}
598 
visit(FieldDeclaration fieldDeclaration, MethodScope scope)599 	public boolean visit(FieldDeclaration fieldDeclaration, MethodScope scope) {
600 		return true; // do nothing by default, keep traversing
601 	}
602 
visit(FieldReference fieldReference, BlockScope scope)603 	public boolean visit(FieldReference fieldReference, BlockScope scope) {
604 		return true; // do nothing by default, keep traversing
605 	}
606 
visit(FloatLiteral floatLiteral, BlockScope scope)607 	public boolean visit(FloatLiteral floatLiteral, BlockScope scope) {
608 		return true; // do nothing by default, keep traversing
609 	}
610 
visit(ForStatement forStatement, BlockScope scope)611 	public boolean visit(ForStatement forStatement, BlockScope scope) {
612 		return true; // do nothing by default, keep traversing
613 	}
614 
visit(IfStatement ifStatement, BlockScope scope)615 	public boolean visit(IfStatement ifStatement, BlockScope scope) {
616 		return true; // do nothing by default, keep traversing
617 	}
618 
visit(ImportReference importRef, CompilationUnitScope scope)619 	public boolean visit(ImportReference importRef, CompilationUnitScope scope) {
620 		return true; // do nothing by default, keep traversing
621 	}
622 
visit(Initializer initializer, MethodScope scope)623 	public boolean visit(Initializer initializer, MethodScope scope) {
624 		return true; // do nothing by default, keep traversing
625 	}
626 
visit(InstanceOfExpression instanceOfExpression, BlockScope scope)627 	public boolean visit(InstanceOfExpression instanceOfExpression,
628 			BlockScope scope) {
629 		return true; // do nothing by default, keep traversing
630 	}
631 
visit(IntLiteral intLiteral, BlockScope scope)632 	public boolean visit(IntLiteral intLiteral, BlockScope scope) {
633 		return true; // do nothing by default, keep traversing
634 	}
635 
visit(LabeledStatement labeledStatement, BlockScope scope)636 	public boolean visit(LabeledStatement labeledStatement, BlockScope scope) {
637 		return true; // do nothing by default, keep traversing
638 	}
639 
visit(LocalDeclaration localDeclaration, BlockScope scope)640 	public boolean visit(LocalDeclaration localDeclaration, BlockScope scope) {
641 		return true; // do nothing by default, keep traversing
642 	}
643 
visit(LongLiteral longLiteral, BlockScope scope)644 	public boolean visit(LongLiteral longLiteral, BlockScope scope) {
645 		return true; // do nothing by default, keep traversing
646 	}
647 
visit(MessageSend messageSend, BlockScope scope)648 	public boolean visit(MessageSend messageSend, BlockScope scope) {
649 		return true; // do nothing by default, keep traversing
650 	}
651 
visit(MethodDeclaration methodDeclaration, ClassScope scope)652 	public boolean visit(MethodDeclaration methodDeclaration, ClassScope scope) {
653 		return true; // do nothing by default, keep traversing
654 	}
655 
656 	// public boolean visit(
657 	// StringLiteralConcatenation literal,
658 	// BlockScope scope) {
659 	// return true; // do nothing by default, keep traversing
660 	// }
visit(NullLiteral nullLiteral, BlockScope scope)661 	public boolean visit(NullLiteral nullLiteral, BlockScope scope) {
662 		return true; // do nothing by default, keep traversing
663 	}
664 
visit(OR_OR_Expression or_or_Expression, BlockScope scope)665 	public boolean visit(OR_OR_Expression or_or_Expression, BlockScope scope) {
666 		return true; // do nothing by default, keep traversing
667 	}
668 
visit(PostfixExpression postfixExpression, BlockScope scope)669 	public boolean visit(PostfixExpression postfixExpression, BlockScope scope) {
670 		return true; // do nothing by default, keep traversing
671 	}
672 
visit(PrefixExpression prefixExpression, BlockScope scope)673 	public boolean visit(PrefixExpression prefixExpression, BlockScope scope) {
674 		return true; // do nothing by default, keep traversing
675 	}
676 
visit( QualifiedAllocationExpression qualifiedAllocationExpression, BlockScope scope)677 	public boolean visit(
678 			QualifiedAllocationExpression qualifiedAllocationExpression,
679 			BlockScope scope) {
680 		return true; // do nothing by default, keep traversing
681 	}
682 
visit(QualifiedNameReference qualifiedNameReference, BlockScope scope)683 	public boolean visit(QualifiedNameReference qualifiedNameReference,
684 			BlockScope scope) {
685 		return true; // do nothing by default, keep traversing
686 	}
687 
visit(QualifiedSuperReference qualifiedSuperReference, BlockScope scope)688 	public boolean visit(QualifiedSuperReference qualifiedSuperReference,
689 			BlockScope scope) {
690 		return true; // do nothing by default, keep traversing
691 	}
692 
visit(QualifiedThisReference qualifiedThisReference, BlockScope scope)693 	public boolean visit(QualifiedThisReference qualifiedThisReference,
694 			BlockScope scope) {
695 		return true; // do nothing by default, keep traversing
696 	}
697 
visit(QualifiedTypeReference qualifiedTypeReference, BlockScope scope)698 	public boolean visit(QualifiedTypeReference qualifiedTypeReference,
699 			BlockScope scope) {
700 		return true; // do nothing by default, keep traversing
701 	}
702 
visit(QualifiedTypeReference qualifiedTypeReference, ClassScope scope)703 	public boolean visit(QualifiedTypeReference qualifiedTypeReference,
704 			ClassScope scope) {
705 		return true; // do nothing by default, keep traversing
706 	}
707 
visit(ReturnStatement returnStatement, BlockScope scope)708 	public boolean visit(ReturnStatement returnStatement, BlockScope scope) {
709 		return true; // do nothing by default, keep traversing
710 	}
711 
visit(SingleNameReference singleNameReference, BlockScope scope)712 	public boolean visit(SingleNameReference singleNameReference,
713 			BlockScope scope) {
714 		return true; // do nothing by default, keep traversing
715 	}
716 
visit(SingleTypeReference singleTypeReference, BlockScope scope)717 	public boolean visit(SingleTypeReference singleTypeReference,
718 			BlockScope scope) {
719 		return true; // do nothing by default, keep traversing
720 	}
721 
visit(SingleTypeReference singleTypeReference, ClassScope scope)722 	public boolean visit(SingleTypeReference singleTypeReference,
723 			ClassScope scope) {
724 		return true; // do nothing by default, keep traversing
725 	}
726 
visit(StringLiteral stringLiteral, BlockScope scope)727 	public boolean visit(StringLiteral stringLiteral, BlockScope scope) {
728 		return true; // do nothing by default, keep traversing
729 	}
730 
visit(SuperReference superReference, BlockScope scope)731 	public boolean visit(SuperReference superReference, BlockScope scope) {
732 		return true; // do nothing by default, keep traversing
733 	}
734 
visit(SwitchStatement switchStatement, BlockScope scope)735 	public boolean visit(SwitchStatement switchStatement, BlockScope scope) {
736 		return true; // do nothing by default, keep traversing
737 	}
738 
visit(ThisReference thisReference, BlockScope scope)739 	public boolean visit(ThisReference thisReference, BlockScope scope) {
740 		return true; // do nothing by default, keep traversing
741 	}
742 
visit(ThrowStatement throwStatement, BlockScope scope)743 	public boolean visit(ThrowStatement throwStatement, BlockScope scope) {
744 		return true; // do nothing by default, keep traversing
745 	}
746 
visit(TrueLiteral trueLiteral, BlockScope scope)747 	public boolean visit(TrueLiteral trueLiteral, BlockScope scope) {
748 		return true; // do nothing by default, keep traversing
749 	}
750 
visit(TryStatement tryStatement, BlockScope scope)751 	public boolean visit(TryStatement tryStatement, BlockScope scope) {
752 		return true; // do nothing by default, keep traversing
753 	}
754 
visit(TypeDeclaration localTypeDeclaration, BlockScope scope)755 	public boolean visit(TypeDeclaration localTypeDeclaration, BlockScope scope) {
756 		return true; // do nothing by default, keep traversing
757 	}
758 
visit(TypeDeclaration memberTypeDeclaration, ClassScope scope)759 	public boolean visit(TypeDeclaration memberTypeDeclaration, ClassScope scope) {
760 		return true; // do nothing by default, keep traversing
761 	}
762 
visit(TypeDeclaration typeDeclaration, CompilationUnitScope scope)763 	public boolean visit(TypeDeclaration typeDeclaration,
764 			CompilationUnitScope scope) {
765 		return true; // do nothing by default, keep traversing
766 	}
767 
visit(UnaryExpression unaryExpression, BlockScope scope)768 	public boolean visit(UnaryExpression unaryExpression, BlockScope scope) {
769 		return true; // do nothing by default, keep traversing
770 	}
771 
visit(WhileStatement whileStatement, BlockScope scope)772 	public boolean visit(WhileStatement whileStatement, BlockScope scope) {
773 		return true; // do nothing by default, keep traversing
774 	}
775 }
776