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

Unified Diff: pkg/yaml/lib/yaml.dart

Issue 11622011: Restructure YAML package suitable for pub lish (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: add yaml exclude Created 7 years, 11 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 | « pkg/yaml/lib/visitor.dart ('k') | pkg/yaml/lib/yaml_map.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/yaml/lib/yaml.dart
diff --git a/utils/pub/yaml/yaml.dart b/pkg/yaml/lib/yaml.dart
similarity index 74%
rename from utils/pub/yaml/yaml.dart
rename to pkg/yaml/lib/yaml.dart
index a73736d4b8b076b90e522a5091f097c94b6d562b..ef0ac830b640035a5e72f7a8d980d7e5fdbe9e9a 100644
--- a/utils/pub/yaml/yaml.dart
+++ b/pkg/yaml/lib/yaml.dart
@@ -2,6 +2,26 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
+/// A parser for [YAML](http://www.yaml.org/).
+///
+/// Use [loadYaml] to load a single document, or [loadYamlStream] to load a
+/// stream of documents. For example:
+///
+/// import 'package:yaml/yaml.dart';
+/// main() {
+/// var doc = loadYaml("YAML: YAML Ain't Markup Language");
+/// print(doc['YAML']);
+/// }
+///
+/// This library currently doesn't support dumping to YAML. You should use
+/// `stringify` from `dart:json` instead:
+///
+/// import 'dart:json' as json;
+/// import 'package:yaml/yaml.dart';
+/// main() {
+/// var doc = loadYaml("YAML: YAML Ain't Markup Language");
+/// print(json.stringify(doc));
+/// }
library yaml;
import 'dart:math' as Math;
« no previous file with comments | « pkg/yaml/lib/visitor.dart ('k') | pkg/yaml/lib/yaml_map.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698