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

Unified Diff: pkg/analyzer/lib/plugin/options.dart

Issue 1392143002: Add context to OptionsProcessor callback API. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Master merge Created 5 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analyzer/CHANGELOG.md ('k') | pkg/analyzer/lib/src/plugin/plugin_configuration.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/plugin/options.dart
diff --git a/pkg/analyzer/lib/plugin/options.dart b/pkg/analyzer/lib/plugin/options.dart
index 65775e1e907c698db08b1293a90808084e3561c6..5abb0349e9695ce5b9d51fbfd3cfe665314bbd9f 100644
--- a/pkg/analyzer/lib/plugin/options.dart
+++ b/pkg/analyzer/lib/plugin/options.dart
@@ -6,6 +6,7 @@
/// analysis options file.
library analyzer.plugin.options;
+import 'package:analyzer/src/generated/engine.dart';
import 'package:analyzer/src/plugin/options_plugin.dart';
import 'package:plugin/plugin.dart';
import 'package:yaml/yaml.dart';
@@ -48,13 +49,15 @@ abstract class OptionsProcessor {
/// Called when an error occurs in processing options.
void onError(Exception exception);
- /// Called when the options file is processed.
+ /// Called when an options file is processed.
///
/// The options file is processed on analyzer initialization and
/// subsequently when the file is changed on disk. In the event of a
/// change notification, note that the notification simply indicates
/// a change on disk. Content in specific option scopes may or may not
/// be different. It is up to the implementer to check whether specific
- /// options have changed and to handle those changes appropriately.
- void optionsProcessed(Map<String, YamlNode> options);
+ /// options have changed and to handle those changes appropriately. In
+ /// addition to the [options] map, the associated analysis [context] is
+ /// provided as well to allow for context-specific configuration.
+ void optionsProcessed(Map<String, YamlNode> options, AnalysisContext context);
Brian Wilkerson 2015/10/08 16:46:47 nit: In general, I like putting collection-valued
pquitslund 2015/10/08 17:09:05 Will do!
}
« no previous file with comments | « pkg/analyzer/CHANGELOG.md ('k') | pkg/analyzer/lib/src/plugin/plugin_configuration.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698