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

Side by Side Diff: pkg/analyzer_plugin/lib/plugin/plugin.dart

Issue 2970203002: Remove references to AnalysisDriver from the plugin mixin classes (Closed)
Patch Set: Created 3 years, 5 months 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) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 import 'dart:async'; 5 import 'dart:async';
6 6
7 import 'package:analyzer/file_system/file_system.dart'; 7 import 'package:analyzer/file_system/file_system.dart';
8 import 'package:analyzer/file_system/physical_file_system.dart'; 8 import 'package:analyzer/file_system/physical_file_system.dart';
9 import 'package:analyzer/src/dart/analysis/driver.dart' 9 import 'package:analyzer/src/dart/analysis/driver.dart'
10 show AnalysisDriverGeneric, AnalysisDriverScheduler; 10 show AnalysisDriverGeneric, AnalysisDriverScheduler;
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 return null; 184 return null;
185 } 185 }
186 186
187 /** 187 /**
188 * Create an analysis driver that can analyze the files within the given 188 * Create an analysis driver that can analyze the files within the given
189 * [contextRoot]. 189 * [contextRoot].
190 */ 190 */
191 AnalysisDriverGeneric createAnalysisDriver(ContextRoot contextRoot); 191 AnalysisDriverGeneric createAnalysisDriver(ContextRoot contextRoot);
192 192
193 /** 193 /**
194 * Return the driver being used to analyze the file with the given [path].
195 */
196 AnalysisDriverGeneric driverForPath(String path) {
mfairhurst 2017/07/05 22:50:51 Isn't this also a public usage of a private API?
Brian Wilkerson 2017/07/05 23:06:49 Yes, it is. But it seemed like an expedient step t
197 ContextRoot contextRoot = contextRootContaining(path);
198 if (contextRoot == null) {
199 return null;
200 }
201 return driverMap[contextRoot];
202 }
203
204 /**
194 * Handle an 'analysis.getNavigation' request. 205 * Handle an 'analysis.getNavigation' request.
195 */ 206 */
196 Future<AnalysisGetNavigationResult> handleAnalysisGetNavigation( 207 Future<AnalysisGetNavigationResult> handleAnalysisGetNavigation(
197 AnalysisGetNavigationParams params) async { 208 AnalysisGetNavigationParams params) async {
198 return new AnalysisGetNavigationResult( 209 return new AnalysisGetNavigationResult(
199 <String>[], <NavigationTarget>[], <NavigationRegion>[]); 210 <String>[], <NavigationTarget>[], <NavigationRegion>[]);
200 } 211 }
201 212
202 /** 213 /**
203 * Handle an 'analysis.handleWatchEvents' request. 214 * Handle an 'analysis.handleWatchEvents' request.
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
571 response = new Response(id, requestTime, 582 response = new Response(id, requestTime,
572 error: new RequestError( 583 error: new RequestError(
573 RequestErrorCode.PLUGIN_ERROR, exception.toString(), 584 RequestErrorCode.PLUGIN_ERROR, exception.toString(),
574 stackTrace: stackTrace.toString())); 585 stackTrace: stackTrace.toString()));
575 } 586 }
576 if (response != null) { 587 if (response != null) {
577 _channel.sendResponse(response); 588 _channel.sendResponse(response);
578 } 589 }
579 } 590 }
580 } 591 }
OLDNEW
« no previous file with comments | « pkg/analyzer_plugin/lib/plugin/navigation_mixin.dart ('k') | pkg/analyzer_plugin/test/plugin/assist_mixin_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698