Tango - shallower hierarchy (was: Phango - questions)
Kris
foo at bar.com
Tue Nov 27 20:07:24 PST 2007
"Chad J" <gamerChad at _spamIsBad_gmail.com> wrote ...
[snip]
>> My propositions:
>> 1. tango.util.collection --> tango.collection
>> 2. tango.util.time --> tango.time
>> 3. tango.util.Convert --> tango.convert.Convert
>>
>> Basically I don't understand why e.g. collection is kind of util? For
>> me "utility" is something more complex, and is similar in meaning to
>> "tool"
>> (something which is produced using basic components). "Utilities" is also
>> used in meaning of "the rest; other things", so IMHO its also not best
>> place for putting collection, time and conversion packages. All these
>> packages represents very basic concepts in every programming language, so
>> they probably deserve its own packages. (I am not native English speaker,
>> so please forgive me if I misinterpreted something here :-])
>>
>> Best Regards
>> Marcin Kuszczak
>> (aarti_pl - www.zapytajmnie.com)
>>
>
> I always get the feeling when using large libs that every hierarchy is
> flawed in bad ways. EVERY hierarchy.
>
> This makes me want to reexamine what I want out of the hierarchy.
> Typically I want to be able to find some functionality of the library in a
> quick fashion.
> This leads me to believe that good search functionality in the docs is the
> key to accomplishing this. It would be great to have some sort of
> powerful search engine for the docs. Something that can see me type
> "templates" and know that I am really looking for "traits".
Couldn't agree more, Chad
This is partly what led to the Tango API web-page being a flat listing where
you can immediately start typing to find something (with FF or whatever).
Between the package names and the module names, you usually hit paydirt very
quickly: http://dsource.org/projects/tango/docs/current/
We've also been playing around with a flat import hierarchy (as an
experiment) where all the imports are in one package, but each import
actually pulls in a few related things. The package name is tentatively
called tango.group, so for example you might have import tango.group.text,
or import tango.group.stream, or import tango.group.time. You get the idea
I'm sure - tango as a library is hierarchical, but you can always import it
via a flat namespace too. Just an experiment that's been lingering for a
while, but driven by what you describe above ... all hierarchies are flawed,
depending on how you choose to look at them.
- Kris
More information about the Digitalmars-d
mailing list