OLD | NEW |
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 analyzer.src.plugin.engine_plugin; | 5 library analyzer.src.plugin.engine_plugin; |
6 | 6 |
7 import 'package:analyzer/plugin/task.dart'; | 7 import 'package:analyzer/plugin/task.dart'; |
8 import 'package:analyzer/src/generated/engine.dart' | 8 import 'package:analyzer/src/generated/engine.dart' |
9 show InternalAnalysisContext; | 9 show InternalAnalysisContext; |
10 import 'package:analyzer/src/generated/error.dart' show AnalysisError; | 10 import 'package:analyzer/src/generated/error.dart' show AnalysisError; |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 void registerExtensions(RegisterExtension registerExtension) { | 163 void registerExtensions(RegisterExtension registerExtension) { |
164 _registerTaskExtensions(registerExtension); | 164 _registerTaskExtensions(registerExtension); |
165 _registerWorkManagerFactoryExtensions(registerExtension); | 165 _registerWorkManagerFactoryExtensions(registerExtension); |
166 _registerDartErrorsForSource(registerExtension); | 166 _registerDartErrorsForSource(registerExtension); |
167 _registerDartErrorsForUnit(registerExtension); | 167 _registerDartErrorsForUnit(registerExtension); |
168 _registerHtmlErrors(registerExtension); | 168 _registerHtmlErrors(registerExtension); |
169 } | 169 } |
170 | 170 |
171 void _registerDartErrorsForSource(RegisterExtension registerExtension) { | 171 void _registerDartErrorsForSource(RegisterExtension registerExtension) { |
172 registerExtension(DART_ERRORS_FOR_SOURCE_EXTENSION_POINT_ID, PARSE_ERRORS); | 172 registerExtension(DART_ERRORS_FOR_SOURCE_EXTENSION_POINT_ID, PARSE_ERRORS); |
173 registerExtension(DART_ERRORS_FOR_SOURCE_EXTENSION_POINT_ID, RESOLVE_DIRECTI
VES_ERRORS); | |
174 registerExtension(DART_ERRORS_FOR_SOURCE_EXTENSION_POINT_ID, SCAN_ERRORS); | 173 registerExtension(DART_ERRORS_FOR_SOURCE_EXTENSION_POINT_ID, SCAN_ERRORS); |
175 } | 174 } |
176 | 175 |
177 void _registerDartErrorsForUnit(RegisterExtension registerExtension) { | 176 void _registerDartErrorsForUnit(RegisterExtension registerExtension) { |
178 registerExtension( | 177 registerExtension( |
179 DART_ERRORS_FOR_UNIT_EXTENSION_POINT_ID, LIBRARY_UNIT_ERRORS); | 178 DART_ERRORS_FOR_UNIT_EXTENSION_POINT_ID, LIBRARY_UNIT_ERRORS); |
180 } | 179 } |
181 | 180 |
182 void _registerHtmlErrors(RegisterExtension registerExtension) { | 181 void _registerHtmlErrors(RegisterExtension registerExtension) { |
183 registerExtension(HTML_ERRORS_EXTENSION_POINT_ID, HTML_DOCUMENT_ERRORS); | 182 registerExtension(HTML_ERRORS_EXTENSION_POINT_ID, HTML_DOCUMENT_ERRORS); |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
225 registerExtension( | 224 registerExtension( |
226 taskId, PropagateVariableTypesInLibraryClosureTask.DESCRIPTOR); | 225 taskId, PropagateVariableTypesInLibraryClosureTask.DESCRIPTOR); |
227 registerExtension(taskId, PropagateVariableTypesInLibraryTask.DESCRIPTOR); | 226 registerExtension(taskId, PropagateVariableTypesInLibraryTask.DESCRIPTOR); |
228 registerExtension(taskId, PropagateVariableTypesInUnitTask.DESCRIPTOR); | 227 registerExtension(taskId, PropagateVariableTypesInUnitTask.DESCRIPTOR); |
229 registerExtension(taskId, PropagateVariableTypeTask.DESCRIPTOR); | 228 registerExtension(taskId, PropagateVariableTypeTask.DESCRIPTOR); |
230 registerExtension(taskId, ReadyLibraryElement2Task.DESCRIPTOR); | 229 registerExtension(taskId, ReadyLibraryElement2Task.DESCRIPTOR); |
231 registerExtension(taskId, ReadyLibraryElement5Task.DESCRIPTOR); | 230 registerExtension(taskId, ReadyLibraryElement5Task.DESCRIPTOR); |
232 registerExtension(taskId, ReadyLibraryElement6Task.DESCRIPTOR); | 231 registerExtension(taskId, ReadyLibraryElement6Task.DESCRIPTOR); |
233 registerExtension(taskId, ReadyResolvedUnitTask.DESCRIPTOR); | 232 registerExtension(taskId, ReadyResolvedUnitTask.DESCRIPTOR); |
234 registerExtension(taskId, ResolveConstantExpressionTask.DESCRIPTOR); | 233 registerExtension(taskId, ResolveConstantExpressionTask.DESCRIPTOR); |
235 registerExtension(taskId, ResolveDirectivesTask.DESCRIPTOR); | |
236 registerExtension(taskId, ResolveDirectiveElementsTask.DESCRIPTOR); | 234 registerExtension(taskId, ResolveDirectiveElementsTask.DESCRIPTOR); |
237 registerExtension(taskId, ResolveInstanceFieldsInUnitTask.DESCRIPTOR); | 235 registerExtension(taskId, ResolveInstanceFieldsInUnitTask.DESCRIPTOR); |
238 registerExtension(taskId, ResolveLibraryReferencesTask.DESCRIPTOR); | 236 registerExtension(taskId, ResolveLibraryReferencesTask.DESCRIPTOR); |
239 registerExtension(taskId, ResolveLibraryTask.DESCRIPTOR); | 237 registerExtension(taskId, ResolveLibraryTask.DESCRIPTOR); |
240 registerExtension(taskId, ResolveLibraryTypeNamesTask.DESCRIPTOR); | 238 registerExtension(taskId, ResolveLibraryTypeNamesTask.DESCRIPTOR); |
241 registerExtension(taskId, ResolveTopLevelLibraryTypeBoundsTask.DESCRIPTOR); | 239 registerExtension(taskId, ResolveTopLevelLibraryTypeBoundsTask.DESCRIPTOR); |
242 registerExtension(taskId, ResolveTopLevelUnitTypeBoundsTask.DESCRIPTOR); | 240 registerExtension(taskId, ResolveTopLevelUnitTypeBoundsTask.DESCRIPTOR); |
243 registerExtension(taskId, ResolveUnitTask.DESCRIPTOR); | 241 registerExtension(taskId, ResolveUnitTask.DESCRIPTOR); |
244 registerExtension(taskId, ResolveUnitTypeNamesTask.DESCRIPTOR); | 242 registerExtension(taskId, ResolveUnitTypeNamesTask.DESCRIPTOR); |
245 registerExtension(taskId, ResolveVariableReferencesTask.DESCRIPTOR); | 243 registerExtension(taskId, ResolveVariableReferencesTask.DESCRIPTOR); |
(...skipping 30 matching lines...) Expand all Loading... |
276 * passed to the extension manager to populate it. | 274 * passed to the extension manager to populate it. |
277 * | 275 * |
278 * This annotation is not used at runtime; it is used to aid in static analysis | 276 * This annotation is not used at runtime; it is used to aid in static analysis |
279 * of the task model during development. | 277 * of the task model during development. |
280 */ | 278 */ |
281 class ExtensionPointId { | 279 class ExtensionPointId { |
282 final String extensionPointId; | 280 final String extensionPointId; |
283 | 281 |
284 const ExtensionPointId(this.extensionPointId); | 282 const ExtensionPointId(this.extensionPointId); |
285 } | 283 } |
OLD | NEW |