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

Unified Diff: sdk/lib/async/deferred_load.dart

Issue 552783002: Update the api-docs to mention that DeferredLibrary is deprecated. (Closed) Base URL: https://dart.googlecode.com/svn/branches/1.6/dart
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/async/deferred_load.dart
diff --git a/sdk/lib/async/deferred_load.dart b/sdk/lib/async/deferred_load.dart
index a770071c8988d0f89c6a316fbac207a44dbe0a22..42db0eeaefaec207e8fd948a72e0cf13fa7a6079 100644
--- a/sdk/lib/async/deferred_load.dart
+++ b/sdk/lib/async/deferred_load.dart
@@ -7,23 +7,11 @@ part of dart.async;
/**
* Indicates that loading of [libraryName] is deferred.
*
- * Applies to library imports, when used as metadata.
+ * This class is deprecated. Instead use the syntax:
+ * `import "library.dart" deferred as prefix;`
*
- * Example usage:
- *
- * @lazy
- * import 'foo.dart' as foo;
- *
- * const lazy = const DeferredLibrary('com.example.foo');
- *
- * void main() {
- * foo.method(); // Throws a NoSuchMethodError, foo is not loaded yet.
- * lazy.load().then(onFooLoaded);
- * }
- *
- * void onFooLoaded(_) {
- * foo.method();
- * }
+ * Read more about the new syntax
+ * [here](https://www.dartlang.org/docs/spec/deferred-loading.html).
*/
class DeferredLibrary {
final String libraryName;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698