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 import 'dart:async'; | 5 import 'dart:async'; |
6 import 'dart:collection'; | 6 import 'dart:collection'; |
7 import 'dart:io' as io; | 7 import 'dart:io' as io; |
8 | 8 |
9 import 'package:analyzer/file_system/file_system.dart' | 9 import 'package:analyzer/file_system/file_system.dart' |
10 show File, Folder, ResourceProvider, ResourceUriResolver; | 10 show File, Folder, ResourceProvider, ResourceUriResolver; |
11 import 'package:analyzer/file_system/physical_file_system.dart'; | 11 import 'package:analyzer/file_system/physical_file_system.dart'; |
12 import 'package:analyzer/source/package_map_resolver.dart'; | 12 import 'package:analyzer/source/package_map_resolver.dart'; |
13 import 'package:analyzer/src/context/builder.dart'; | 13 import 'package:analyzer/src/context/builder.dart'; |
14 import 'package:analyzer/src/dart/analysis/driver.dart'; | 14 import 'package:analyzer/src/dart/analysis/driver.dart'; |
15 import 'package:analyzer/src/dart/analysis/file_state.dart'; | 15 import 'package:analyzer/src/dart/analysis/file_state.dart'; |
16 import 'package:analyzer/src/dart/sdk/sdk.dart'; | 16 import 'package:analyzer/src/dart/sdk/sdk.dart'; |
17 import 'package:analyzer/src/generated/engine.dart' hide AnalysisResult; | 17 import 'package:analyzer/src/generated/engine.dart' hide AnalysisResult; |
18 import 'package:analyzer/src/generated/sdk.dart'; | 18 import 'package:analyzer/src/generated/sdk.dart'; |
19 import 'package:analyzer/src/generated/source.dart'; | 19 import 'package:analyzer/src/generated/source.dart'; |
20 import 'package:analyzer/src/generated/source_io.dart'; | 20 import 'package:analyzer/src/generated/source_io.dart'; |
21 import 'package:analyzer/src/lint/io.dart'; | 21 import 'package:analyzer/src/lint/io.dart'; |
22 import 'package:analyzer/src/lint/linter.dart'; | 22 import 'package:analyzer/src/lint/linter.dart'; |
23 import 'package:analyzer/src/lint/project.dart'; | 23 import 'package:analyzer/src/lint/project.dart'; |
24 import 'package:analyzer/src/lint/registry.dart'; | 24 import 'package:analyzer/src/lint/registry.dart'; |
25 import 'package:analyzer/src/services/lint.dart'; | 25 import 'package:analyzer/src/services/lint.dart'; |
26 import 'package:analyzer/src/util/sdk.dart'; | 26 import 'package:analyzer/src/util/sdk.dart'; |
27 import 'package:front_end/src/base/performace_logger.dart'; | 27 import 'package:front_end/src/base/performace_logger.dart'; |
28 import 'package:front_end/src/incremental/byte_store.dart'; | 28 import 'package:front_end/src/byte_store/byte_store.dart'; |
29 import 'package:package_config/packages.dart' show Packages; | 29 import 'package:package_config/packages.dart' show Packages; |
30 import 'package:package_config/packages_file.dart' as pkgfile show parse; | 30 import 'package:package_config/packages_file.dart' as pkgfile show parse; |
31 import 'package:package_config/src/packages_impl.dart' show MapPackages; | 31 import 'package:package_config/src/packages_impl.dart' show MapPackages; |
32 import 'package:path/path.dart' as p; | 32 import 'package:path/path.dart' as p; |
33 import 'package:plugin/manager.dart'; | 33 import 'package:plugin/manager.dart'; |
34 import 'package:plugin/plugin.dart'; | 34 import 'package:plugin/plugin.dart'; |
35 | 35 |
36 Source createSource(Uri sourceUri) { | 36 Source createSource(Uri sourceUri) { |
37 return PhysicalResourceProvider.INSTANCE | 37 return PhysicalResourceProvider.INSTANCE |
38 .getFile(sourceUri.toFilePath()) | 38 .getFile(sourceUri.toFilePath()) |
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 } | 234 } |
235 | 235 |
236 /// Prints logging information comments to the [outSink] and error messages to | 236 /// Prints logging information comments to the [outSink] and error messages to |
237 /// [errorSink]. | 237 /// [errorSink]. |
238 class StdLogger extends Logger { | 238 class StdLogger extends Logger { |
239 @override | 239 @override |
240 void logError(String message, [exception]) => errorSink.writeln(message); | 240 void logError(String message, [exception]) => errorSink.writeln(message); |
241 @override | 241 @override |
242 void logInformation(String message, [exception]) => outSink.writeln(message); | 242 void logInformation(String message, [exception]) => outSink.writeln(message); |
243 } | 243 } |
OLD | NEW |