Stewart Stremler wrote: > Elsethread it was recommended that we have package-level documentation, > which I thing would be pretty useful as well.
I definitely agree.
> A parent- and child-hierarchy and a used-by list would be on my wishlist.
What is used-by? A reversed pre-requisites? Try the attached. That's
generated from:
| pkgs usedBy |
pkgs := PackageLoader packages.
usedBy := LookupTable new: pkgs size.
pkgs do: [ :pkg | usedBy at: pkg name put: Set new ].
pkgs do:
[ :pkg | pkg prerequisites do:
[ :prq | usedBy at: prq ifPresent:
[ :set | set add: pkg name ] ] ].
Incidentally, that showed up that DhbNumericalMethods relies on
DhbNumericalMethodsExtensions, which doesn't exist.
> The document writer could put in type hints for the document reader,
> as the document reader needs more information than the code reader...
>
> " ...
> @arg start a {Number} not less than 0 indicating the start position.
> @arg end a {Number} not less than _start_ indicating the end position.
> ..."
>
> (Mabye type-hints? e.g. "@arg Number start ...." -- but that feels
> like it would go terribly wrong...)
I'd say so:
Object >> perform: selectorOrMessageOrMethod
"Send the unary message named selectorOrMessageOrMethod (if a Symbol) to
the receiver, or the message and arguments it identifies (if a Message
or DirectedMessage), or finally execute the method within the receiver
(if a CompiledMethod). ..."
Regards,
Mike
GDBM
Pre-requisites
None
Used by
None
I18N
Pre-requisites
None
Used by
None
MD5
Pre-requisites
None
Used by
None
"======================================================================
|
| Copyright 2006 Mike Anderson
| Written by Mike Anderson
|
| This file is part of Mumble, a development environment for GNU Smalltalk.
|
| Mumble is free software; you can redistribute it and/or modify it
| under the terms of the GNU General Public License as published by the Free
| Software Foundation; either version 2, or (at your option) any later version.
|
| Mumble is distributed in the hope that it will be useful, but WITHOUT
| ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
| FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
| details.
|
| You should have received a copy of the GNU General Public License along with
| Mumble; see the file COPYING. If not, write to the Free Software
| Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
======================================================================
"
BrowserInitializeResponse subclass: #PackagesInitResponse
!
PackagesInitResponse methodsFor: 'everything'!
selfUrl
^'/Browser/Packages'.
!
sendPackageList: aNames heading: aHeading
self element: 'h4'; text: aHeading; end: 'h4'.
aNames isEmpty
ifTrue:
[ self element: 'p'; text: 'None'; end: 'p' ]
ifFalse:
[ self element: 'ul'.
aNames asSortedCollection do:
[ :name |
self
element: 'li';
element: 'a';
attribute: 'href' value: '#', name;
text: name;
end: 'a';
end: 'li'. ].
self end: 'ul'. ].
!
sendBodyContent
| pkgs usedBy |
pkgs := PackageLoader packages.
usedBy := LookupTable new: pkgs size.
pkgs do: [ :pkg | usedBy at: pkg name put: Set new ].
pkgs do:
[ :pkg | pkg prerequisites do:
[ :prq | usedBy at: prq ifPresent:
[ :set | set add: pkg name ] ] ].
(pkgs asSortedCollection:
[ :a :b | a name < b name ])
do:
[ :pkg |
self
element: 'div';
attribute: 'id' value: pkg name;
element: 'h3';
text: pkg name;
end: 'h3';
sendPackageList: pkg prerequisites heading:
'Pre-requisites';
sendPackageList: (usedBy at: pkg name) heading: 'Used
by';
end: 'div'. ].
!
initScript
^''
"^'get_and_eval(''', self selfUrl, '?Name=Smalltalk'',
document.getElementById(''root''));'"
!
!
_______________________________________________ help-smalltalk mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-smalltalk
