OLD | NEW |
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 import 'dart:collection'; | 6 import 'dart:collection'; |
7 import 'dart:io' show Platform; | 7 import 'dart:io' show Platform; |
8 | 8 |
9 import 'package:analysis_server/src/plugin/notification_manager.dart'; | 9 import 'package:analysis_server/src/plugin/notification_manager.dart'; |
10 import 'package:analyzer/context/context_root.dart' as analyzer; | 10 import 'package:analyzer/context/context_root.dart' as analyzer; |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 */ | 215 */ |
216 ServerCommunicationChannel _createChannel(); | 216 ServerCommunicationChannel _createChannel(); |
217 | 217 |
218 /** | 218 /** |
219 * Update the context roots that the plugin should be analyzing. | 219 * Update the context roots that the plugin should be analyzing. |
220 */ | 220 */ |
221 void _updatePluginRoots() { | 221 void _updatePluginRoots() { |
222 if (currentSession != null) { | 222 if (currentSession != null) { |
223 AnalysisSetContextRootsParams params = new AnalysisSetContextRootsParams( | 223 AnalysisSetContextRootsParams params = new AnalysisSetContextRootsParams( |
224 contextRoots | 224 contextRoots |
225 .map((analyzer.ContextRoot contextRoot) => | 225 .map((analyzer.ContextRoot contextRoot) => new ContextRoot( |
226 new ContextRoot(contextRoot.root, contextRoot.exclude)) | 226 contextRoot.root, contextRoot.exclude, |
| 227 optionsFile: contextRoot.optionsFilePath)) |
227 .toList()); | 228 .toList()); |
228 currentSession.sendRequest(params); | 229 currentSession.sendRequest(params); |
229 } | 230 } |
230 } | 231 } |
231 } | 232 } |
232 | 233 |
233 /** | 234 /** |
234 * An object used to manage the currently running plugins. | 235 * An object used to manage the currently running plugins. |
235 */ | 236 */ |
236 class PluginManager { | 237 class PluginManager { |
(...skipping 642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
879 * The completer that will be used to complete the future when the response is | 880 * The completer that will be used to complete the future when the response is |
880 * received from the plugin. | 881 * received from the plugin. |
881 */ | 882 */ |
882 final Completer<Response> completer; | 883 final Completer<Response> completer; |
883 | 884 |
884 /** | 885 /** |
885 * Initialize a pending request. | 886 * Initialize a pending request. |
886 */ | 887 */ |
887 _PendingRequest(this.method, this.requestTime, this.completer); | 888 _PendingRequest(this.method, this.requestTime, this.completer); |
888 } | 889 } |
OLD | NEW |