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

Unified Diff: pkg/analyzer/lib/src/plugin/options_plugin.dart

Issue 2569603002: Remove the options plugin (Closed)
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/lib/src/plugin/engine_plugin.dart ('k') | pkg/analyzer/lib/src/task/options.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/plugin/options_plugin.dart
diff --git a/pkg/analyzer/lib/src/plugin/options_plugin.dart b/pkg/analyzer/lib/src/plugin/options_plugin.dart
deleted file mode 100644
index f7f7bbca7104e78178349c1c961d810ab9281230..0000000000000000000000000000000000000000
--- a/pkg/analyzer/lib/src/plugin/options_plugin.dart
+++ /dev/null
@@ -1,50 +0,0 @@
-// Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-library analyzer.src.plugin.options_plugin;
-
-import 'package:analyzer/plugin/options.dart';
-import 'package:analyzer/plugin/task.dart';
-import 'package:analyzer/src/task/options.dart';
-import 'package:plugin/plugin.dart';
-
-/// A plugin that defines the extension points and extensions that are defined
-/// by applications that want to consume options defined in the analysis
-/// options file.
-class OptionsPlugin implements Plugin {
- /// The simple identifier of the extension point that allows plugins to
- /// register new options validators.
- static const String OPTIONS_VALIDATOR_EXTENSION_POINT = 'optionsValidator';
-
- /// The unique identifier of this plugin.
- static const String UNIQUE_IDENTIFIER = 'options.core';
-
- /// The extension point that allows plugins to register new options
- /// validators.
- ExtensionPoint<OptionsValidator> optionsValidatorExtensionPoint;
-
- /// All contributed options validators.
- List<OptionsValidator> get optionsValidators =>
- optionsValidatorExtensionPoint?.extensions ?? const <OptionsValidator>[];
-
- @override
- String get uniqueIdentifier => UNIQUE_IDENTIFIER;
-
- @override
- void registerExtensionPoints(RegisterExtensionPoint registerExtensionPoint) {
- optionsValidatorExtensionPoint = new ExtensionPoint<OptionsValidator>(
- this, OPTIONS_VALIDATOR_EXTENSION_POINT, null);
- registerExtensionPoint(optionsValidatorExtensionPoint);
- }
-
- @override
- void registerExtensions(RegisterExtension registerExtension) {
- // Analyze options files.
- registerExtension(
- TASK_EXTENSION_POINT_ID, GenerateOptionsErrorsTask.DESCRIPTOR);
- // Validate analyzer analysis options.
- registerExtension(
- OPTIONS_VALIDATOR_EXTENSION_POINT_ID, new AnalyzerOptionsValidator());
- }
-}
« no previous file with comments | « pkg/analyzer/lib/src/plugin/engine_plugin.dart ('k') | pkg/analyzer/lib/src/task/options.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698