| OLD | NEW |
| 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, 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.sdk; | 5 library analyzer.src.generated.sdk; |
| 6 | 6 |
| 7 import 'dart:collection'; | 7 import 'dart:collection'; |
| 8 | 8 |
| 9 import 'package:analyzer/dart/ast/ast.dart'; | 9 import 'package:analyzer/dart/ast/ast.dart'; |
| 10 import 'package:analyzer/dart/ast/visitor.dart'; | 10 import 'package:analyzer/dart/ast/visitor.dart'; |
| 11 import 'package:analyzer/src/generated/engine.dart' | 11 import 'package:analyzer/src/generated/engine.dart' |
| 12 show AnalysisContext, AnalysisOptions, AnalysisOptionsImpl; | 12 show AnalysisContext, AnalysisOptions, AnalysisOptionsImpl; |
| 13 import 'package:analyzer/src/generated/source.dart' show Source; | 13 import 'package:analyzer/src/generated/source.dart' show Source; |
| 14 import 'package:analyzer/src/generated/utilities_general.dart'; | 14 import 'package:analyzer/src/generated/utilities_general.dart'; |
| 15 import 'package:analyzer/src/summary/idl.dart' show PackageBundle; |
| 15 | 16 |
| 16 /** | 17 /** |
| 17 * A function used to create a new DartSdk with the given [options]. If the | 18 * A function used to create a new DartSdk with the given [options]. If the |
| 18 * passed [options] are `null`, then default options are used. | 19 * passed [options] are `null`, then default options are used. |
| 19 */ | 20 */ |
| 20 typedef DartSdk SdkCreator(AnalysisOptions options); | 21 typedef DartSdk SdkCreator(AnalysisOptions options); |
| 21 | 22 |
| 22 /** | 23 /** |
| 23 * A Dart SDK installed in a specified location. | 24 * A Dart SDK installed in a specified location. |
| 24 */ | 25 */ |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 */ | 72 */ |
| 72 List<String> get uris; | 73 List<String> get uris; |
| 73 | 74 |
| 74 /** | 75 /** |
| 75 * Return a source representing the given 'file:' [uri] if the file is in this | 76 * Return a source representing the given 'file:' [uri] if the file is in this |
| 76 * SDK, or `null` if the file is not in this SDK. | 77 * SDK, or `null` if the file is not in this SDK. |
| 77 */ | 78 */ |
| 78 Source fromFileUri(Uri uri); | 79 Source fromFileUri(Uri uri); |
| 79 | 80 |
| 80 /** | 81 /** |
| 82 * Return the linked [PackageBundle] for this SDK, if it can be provided, or |
| 83 * `null` otherwise. |
| 84 * |
| 85 * This is a temporary API, don't use it. |
| 86 */ |
| 87 PackageBundle getLinkedBundle(); |
| 88 |
| 89 /** |
| 81 * Return the library representing the library with the given 'dart:' [uri], | 90 * Return the library representing the library with the given 'dart:' [uri], |
| 82 * or `null` if the given URI does not denote a library in this SDK. | 91 * or `null` if the given URI does not denote a library in this SDK. |
| 83 */ | 92 */ |
| 84 SdkLibrary getSdkLibrary(String uri); | 93 SdkLibrary getSdkLibrary(String uri); |
| 85 | 94 |
| 86 /** | 95 /** |
| 87 * Return the source representing the library with the given 'dart:' [uri], or | 96 * Return the source representing the library with the given 'dart:' [uri], or |
| 88 * `null` if the given URI does not denote a library in this SDK. | 97 * `null` if the given URI does not denote a library in this SDK. |
| 89 */ | 98 */ |
| 90 Source mapDartUri(String uri); | 99 Source mapDartUri(String uri); |
| (...skipping 458 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 549 _platforms |= DART2JS_PLATFORM; | 558 _platforms |= DART2JS_PLATFORM; |
| 550 } | 559 } |
| 551 | 560 |
| 552 /** | 561 /** |
| 553 * Record that this library can be run on the VM. | 562 * Record that this library can be run on the VM. |
| 554 */ | 563 */ |
| 555 void setVmLibrary() { | 564 void setVmLibrary() { |
| 556 _platforms |= VM_PLATFORM; | 565 _platforms |= VM_PLATFORM; |
| 557 } | 566 } |
| 558 } | 567 } |
| OLD | NEW |