Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(514)

Side by Side Diff: pkg/analysis_server/lib/src/services/search/element_visitors.dart

Issue 1527793003: Clean up imports in analysis_server and analyzer_cli (and one missed in analyzer) (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library services.search.element_visitors; 5 library services.search.element_visitors;
6 6
7 import 'package:analyzer/src/generated/element.dart'; 7 import 'package:analyzer/dart/element/element.dart';
8 import 'package:analyzer/dart/element/visitor.dart';
8 9
9 /** 10 /**
10 * Uses [processor] to visit all of the children of [element]. 11 * Uses [processor] to visit all of the children of [element].
11 * If [processor] returns `true`, then children of a child are visited too. 12 * If [processor] returns `true`, then children of a child are visited too.
12 */ 13 */
13 void visitChildren(Element element, ElementProcessor processor) { 14 void visitChildren(Element element, ElementProcessor processor) {
14 element.visitChildren(new _ElementVisitorAdapter(processor)); 15 element.visitChildren(new _ElementVisitorAdapter(processor));
15 } 16 }
16 17
17 /** 18 /**
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 56
56 @override 57 @override
57 void visitElement(Element element) { 58 void visitElement(Element element) {
58 if (element is CompilationUnitElement) { 59 if (element is CompilationUnitElement) {
59 element.visitChildren(this); 60 element.visitChildren(this);
60 } else { 61 } else {
61 processor(element); 62 processor(element);
62 } 63 }
63 } 64 }
64 } 65 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698