Index: pkg/analyzer/lib/src/generated/sdk_io.dart |
diff --git a/pkg/analyzer/lib/src/generated/sdk_io.dart b/pkg/analyzer/lib/src/generated/sdk_io.dart |
index be7c27a6a4b97958fa45eb4a07d8b1c7d053258d..50cb9d066fb7cf512c51c2c6c888ef6499a923f4 100644 |
--- a/pkg/analyzer/lib/src/generated/sdk_io.dart |
+++ b/pkg/analyzer/lib/src/generated/sdk_io.dart |
@@ -108,6 +108,20 @@ abstract class AbstractDartSdk implements DartSdk { |
_useSummary = use; |
} |
+ /** |
+ * Add the extensions from one or more sdk extension files to this sdk. The |
+ * [extensions] should be a table mapping the names of extensions to the paths |
+ * where those extensions can be found. |
+ */ |
+ void addExtensions(Map<String, String> extensions) { |
+ extensions.forEach((String uri, String path) { |
+ String shortName = uri.substring(uri.indexOf(':') + 1); |
+ SdkLibraryImpl library = new SdkLibraryImpl(shortName); |
+ library.path = path; |
+ libraryMap.setLibrary(uri, library); |
+ }); |
+ } |
+ |
@override |
Source fromFileUri(Uri uri) { |
JavaFile file = new JavaFile.fromUri(uri); |