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

Side by Side Diff: pkg/dartdoc/lib/dartdoc.dart

Issue 11036058: Show top-level members (again). (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comment. Created 8 years, 2 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 | « no previous file | pkg/dartdoc/lib/src/client/dropdown.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 * To generate docs for a library, run this script with the path to an 6 * To generate docs for a library, run this script with the path to an
7 * entrypoint .dart file, like: 7 * entrypoint .dart file, like:
8 * 8 *
9 * $ dart dartdoc.dart foo.dart 9 * $ dart dartdoc.dart foo.dart
10 * 10 *
(...skipping 983 matching lines...) Expand 10 before | Expand all | Expand 10 after
994 void docMembers(ObjectMirror host) { 994 void docMembers(ObjectMirror host) {
995 // Collect the different kinds of members. 995 // Collect the different kinds of members.
996 final staticMethods = []; 996 final staticMethods = [];
997 final staticFields = []; 997 final staticFields = [];
998 final memberMap = new Map<String,MemberMirror>(); 998 final memberMap = new Map<String,MemberMirror>();
999 final instanceMethods = []; 999 final instanceMethods = [];
1000 final instanceFields = []; 1000 final instanceFields = [];
1001 1001
1002 host.declaredMembers.forEach((_, MemberMirror member) { 1002 host.declaredMembers.forEach((_, MemberMirror member) {
1003 if (member.isPrivate) return; 1003 if (member.isPrivate) return;
1004 if (member.isStatic) { 1004 if (host is LibraryMirror || member.isStatic) {
1005 if (member.isMethod) { 1005 if (member.isMethod) {
1006 staticMethods.add(member); 1006 staticMethods.add(member);
1007 } else if (member.isField) { 1007 } else if (member.isField) {
1008 staticFields.add(member); 1008 staticFields.add(member);
1009 } 1009 }
1010 } 1010 }
1011 }); 1011 });
1012 1012
1013 if (host is InterfaceMirror) { 1013 if (host is InterfaceMirror) {
1014 var iterable = new HierarchyIterable(host, includeType: true); 1014 var iterable = new HierarchyIterable(host, includeType: true);
(...skipping 624 matching lines...) Expand 10 before | Expand all | Expand 10 after
1639 final InterfaceMirror inheritedFrom; 1639 final InterfaceMirror inheritedFrom;
1640 1640
1641 DocComment(this.text, [this.inheritedFrom = null]) { 1641 DocComment(this.text, [this.inheritedFrom = null]) {
1642 assert(text != null && !text.trim().isEmpty()); 1642 assert(text != null && !text.trim().isEmpty());
1643 } 1643 }
1644 1644
1645 String get html => md.markdownToHtml(text); 1645 String get html => md.markdownToHtml(text);
1646 1646
1647 String toString() => text; 1647 String toString() => text;
1648 } 1648 }
OLDNEW
« no previous file with comments | « no previous file | pkg/dartdoc/lib/src/client/dropdown.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698