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

Side by Side Diff: utils/apidoc/apidoc.dart

Issue 14251006: Remove AsyncError with Expando. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 7 years, 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « tools/version.dart ('k') | utils/pub/command_lish.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 /** 5 /**
6 * This generates the reference documentation for the core libraries that come 6 * This generates the reference documentation for the core libraries that come
7 * with dart. It is built on top of dartdoc, which is a general-purpose library 7 * with dart. It is built on top of dartdoc, which is a general-purpose library
8 * for generating docs from any Dart code. This library extends that to include 8 * for generating docs from any Dart code. This library extends that to include
9 * additional information and styling specific to our standard library. 9 * additional information and styling specific to our standard library.
10 * 10 *
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 apidoc.includedLibraries = includedLibraries; 148 apidoc.includedLibraries = includedLibraries;
149 149
150 // TODO(amouravski): make apidoc use roughly the same flow as bin/dartdoc. 150 // TODO(amouravski): make apidoc use roughly the same flow as bin/dartdoc.
151 Future.wait([copiedStatic, copiedApiDocStatic, htmlDiff]) 151 Future.wait([copiedStatic, copiedApiDocStatic, htmlDiff])
152 .then((_) => apidoc.documentLibraries(apidocLibraries, libPath, 152 .then((_) => apidoc.documentLibraries(apidocLibraries, libPath,
153 packageRoot)) 153 packageRoot))
154 .then((_) => compileScript(mode, outputDir, libPath)) 154 .then((_) => compileScript(mode, outputDir, libPath))
155 .then((_) => print(apidoc.status)) 155 .then((_) => print(apidoc.status))
156 .catchError((e) { 156 .catchError((e) {
157 print('Error: generation failed: ${e}'); 157 print('Error: generation failed: ${e}');
158 var trace = getAttachedStackTrace(e);
159 if (trace != null) print("StackTrace: $trace");
158 apidoc.cleanup(); 160 apidoc.cleanup();
159 exit(1); 161 exit(1);
160 }) 162 })
161 .whenComplete(() => apidoc.cleanup()); 163 .whenComplete(() => apidoc.cleanup());
162 }); 164 });
163 } 165 }
164 166
165 class Apidoc extends Dartdoc { 167 class Apidoc extends Dartdoc {
166 /** Big ball of JSON containing the scraped MDN documentation. */ 168 /** Big ball of JSON containing the scraped MDN documentation. */
167 final Map mdn; 169 final Map mdn;
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
453 /** Converts a local path string to a `file:` [Uri]. */ 455 /** Converts a local path string to a `file:` [Uri]. */
454 Uri _pathToFileUri(String path) { 456 Uri _pathToFileUri(String path) {
455 path = pathos.absolute(path); 457 path = pathos.absolute(path);
456 if (Platform.operatingSystem != 'windows') { 458 if (Platform.operatingSystem != 'windows') {
457 return Uri.parse('file://$path'); 459 return Uri.parse('file://$path');
458 } else { 460 } else {
459 return Uri.parse('file:///${path.replaceAll("\\", "/")}'); 461 return Uri.parse('file:///${path.replaceAll("\\", "/")}');
460 } 462 }
461 } 463 }
462 464
OLDNEW
« no previous file with comments | « tools/version.dart ('k') | utils/pub/command_lish.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698