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

Side by Side Diff: pkg/analyzer/lib/src/plugin/options_plugin.dart

Issue 1322513004: Reformat code to reduce churn (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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
« no previous file with comments | « pkg/analyzer/lib/src/generated/visitors.dart ('k') | pkg/analyzer/lib/src/services/lint.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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.options; 5 library analyzer.src.plugin.options;
6 6
7 import 'package:analyzer/plugin/options.dart'; 7 import 'package:analyzer/plugin/options.dart';
8 import 'package:plugin/plugin.dart'; 8 import 'package:plugin/plugin.dart';
9 9
10 /// A plugin that defines the extension points and extensions that are defined 10 /// A plugin that defines the extension points and extensions that are defined
11 /// by applications that want to consume options defined in the analysis 11 /// by applications that want to consume options defined in the analysis
12 /// options file. 12 /// options file.
13 class OptionsPlugin implements Plugin { 13 class OptionsPlugin implements Plugin {
14
15 /// The simple identifier of the extension point that allows plugins to 14 /// The simple identifier of the extension point that allows plugins to
16 /// register new options processors. 15 /// register new options processors.
17 static const String OPTIONS_PROCESSOR_EXTENSION_POINT = 'optionsProcessor'; 16 static const String OPTIONS_PROCESSOR_EXTENSION_POINT = 'optionsProcessor';
18 17
19 /// The unique identifier of this plugin. 18 /// The unique identifier of this plugin.
20 static const String UNIQUE_IDENTIFIER = 'options.core'; 19 static const String UNIQUE_IDENTIFIER = 'options.core';
21 20
22 /// The extension point that allows plugins to register new options processors . 21 /// The extension point that allows plugins to register new options processors .
23 ExtensionPoint optionsProcessorExtensionPoint; 22 ExtensionPoint optionsProcessorExtensionPoint;
24 23
(...skipping 17 matching lines...) Expand all
42 41
43 /// Validate the given extension by throwing an [ExtensionError] if it is not a 42 /// Validate the given extension by throwing an [ExtensionError] if it is not a
44 /// valid options processor. 43 /// valid options processor.
45 void _validateOptionsProcessorExtension(Object extension) { 44 void _validateOptionsProcessorExtension(Object extension) {
46 if (extension is! OptionsProcessor) { 45 if (extension is! OptionsProcessor) {
47 String id = optionsProcessorExtensionPoint.uniqueIdentifier; 46 String id = optionsProcessorExtensionPoint.uniqueIdentifier;
48 throw new ExtensionError('Extensions to $id must be an OptionsProcessor'); 47 throw new ExtensionError('Extensions to $id must be an OptionsProcessor');
49 } 48 }
50 } 49 }
51 } 50 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/generated/visitors.dart ('k') | pkg/analyzer/lib/src/services/lint.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698