OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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.generated.workspace; | 5 library analyzer.src.generated.workspace; |
6 | 6 |
7 import 'package:analyzer/file_system/file_system.dart'; | 7 import 'package:analyzer/file_system/file_system.dart'; |
8 import 'package:analyzer/src/generated/sdk.dart'; | 8 import 'package:analyzer/src/generated/sdk.dart'; |
9 import 'package:analyzer/src/generated/source.dart'; | 9 import 'package:analyzer/src/generated/source.dart'; |
10 | 10 |
11 /** | 11 /** |
12 * Abstract superclass of classes that provide information about the workspace | 12 * Abstract superclass of classes that provide information about the workspace |
13 * in which analysis is being performed. | 13 * in which analysis is being performed. |
14 */ | 14 */ |
15 abstract class Workspace { | 15 abstract class Workspace { |
16 | |
17 /** | 16 /** |
18 * Return a map of package sources. | 17 * Return a map of package sources. |
19 */ | 18 */ |
20 Map<String, List<Folder>> get packageMap; | 19 Map<String, List<Folder>> get packageMap; |
21 | 20 |
22 /** | 21 /** |
23 * The [UriResolver] that can resolve `package` URIs. | 22 * The [UriResolver] that can resolve `package` URIs. |
24 */ | 23 */ |
25 UriResolver get packageUriResolver; | 24 UriResolver get packageUriResolver; |
26 | 25 |
27 /** | 26 /** |
28 * Return `true` if this workspace defines a single "project" | 27 * Return `true` if this workspace defines a single "project" |
29 * and that "project" depends upon flutter, | 28 * and that "project" depends upon flutter, |
30 */ | 29 */ |
31 bool get hasFlutterDependency => false; | 30 bool get hasFlutterDependency => false; |
32 | 31 |
33 /** | 32 /** |
34 * Create the [SourceFactory] for resolving Uris to [Source]s. | 33 * Create the [SourceFactory] for resolving Uris to [Source]s. |
35 * The [sdk] may be `null`. | 34 * The [sdk] may be `null`. |
36 */ | 35 */ |
37 SourceFactory createSourceFactory(DartSdk sdk); | 36 SourceFactory createSourceFactory(DartSdk sdk); |
38 } | 37 } |
OLD | NEW |