OLD | NEW |
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 * A script to assist in documenting the difference between the dart:html API | 6 * A script to assist in documenting the difference between the dart:html API |
7 * and the old DOM API. | 7 * and the old DOM API. |
8 */ | 8 */ |
9 #library('html_diff'); | 9 #library('html_diff'); |
10 | 10 |
11 #import('../../../frog/lang.dart'); | 11 #import('../../frog/lang.dart'); |
12 #import('../../../frog/file_system_node.dart'); | 12 #import('../../frog/file_system_node.dart'); |
13 #import('../../../frog/file_system.dart'); | 13 #import('../../frog/file_system.dart'); |
14 #import('../../../utils/dartdoc/dartdoc.dart'); | 14 #import('../dartdoc/dartdoc.dart'); |
15 | 15 |
16 void main() { | 16 void main() { |
17 var files = new NodeFileSystem(); | 17 var files = new NodeFileSystem(); |
18 parseOptions('../../frog', [] /* args */, files); | 18 parseOptions('../../frog', [] /* args */, files); |
19 initializeWorld(files); | 19 initializeWorld(files); |
20 initializeDartDoc(); | 20 initializeDartDoc(); |
21 HtmlDiff.initialize(); | 21 HtmlDiff.initialize(); |
22 | 22 |
23 var diff = new HtmlDiff(); | 23 var diff = new HtmlDiff(); |
24 diff.run(); | 24 diff.run(); |
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
425 Map<String, String> _getTags(String comment) { | 425 Map<String, String> _getTags(String comment) { |
426 if (comment == null) return const <String>{}; | 426 if (comment == null) return const <String>{}; |
427 final re = new RegExp("@([a-zA-Z]+) ([^;]+)(?:;|\$)"); | 427 final re = new RegExp("@([a-zA-Z]+) ([^;]+)(?:;|\$)"); |
428 final tags = <String>{}; | 428 final tags = <String>{}; |
429 for (var m in re.allMatches(comment.trim())) { | 429 for (var m in re.allMatches(comment.trim())) { |
430 tags[m[1]] = m[2]; | 430 tags[m[1]] = m[2]; |
431 } | 431 } |
432 return tags; | 432 return tags; |
433 } | 433 } |
434 } | 434 } |
OLD | NEW |