OLD | NEW |
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 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 break; | 56 break; |
57 | 57 |
58 default: | 58 default: |
59 if (arg.startsWith('--exclude-lib=')) { | 59 if (arg.startsWith('--exclude-lib=')) { |
60 excludedLibraries.add(arg.substring('--exclude-lib='.length)); | 60 excludedLibraries.add(arg.substring('--exclude-lib='.length)); |
61 } else if (arg.startsWith('--include-lib=')) { | 61 } else if (arg.startsWith('--include-lib=')) { |
62 includedLibraries.add(arg.substring('--include-lib='.length)); | 62 includedLibraries.add(arg.substring('--include-lib='.length)); |
63 } else if (arg.startsWith('--out=')) { | 63 } else if (arg.startsWith('--out=')) { |
64 outputDir = new Path(arg.substring('--out='.length)); | 64 outputDir = new Path(arg.substring('--out='.length)); |
65 } else if (arg.startsWith('--pkg=')) { | 65 } else if (arg.startsWith('--pkg=')) { |
66 pkgPath = arg.substring('--pkg='.length); | 66 pkgPath = new Path(arg.substring('--pkg='.length)); |
67 } else { | 67 } else { |
68 print('Unknown option: $arg'); | 68 print('Unknown option: $arg'); |
69 return; | 69 return; |
70 } | 70 } |
71 break; | 71 break; |
72 } | 72 } |
73 } | 73 } |
74 | 74 |
75 final libPath = doc.scriptDir.append('../../sdk/'); | 75 final libPath = doc.scriptDir.append('../../sdk/'); |
76 | 76 |
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
455 return ''' | 455 return ''' |
456 <div class="mdn"> | 456 <div class="mdn"> |
457 $mdnComment | 457 $mdnComment |
458 <div class="mdn-note"><a href="$mdnUrl">from MDN</a></div> | 458 <div class="mdn-note"><a href="$mdnUrl">from MDN</a></div> |
459 </div> | 459 </div> |
460 '''; | 460 '''; |
461 } | 461 } |
462 | 462 |
463 String toString() => mdnComment; | 463 String toString() => mdnComment; |
464 } | 464 } |
OLD | NEW |