[ng-dhtml] directory structure

Alex Russell alex at netWindows.org
Thu Sep 16 13:18:45 CDT 2004

Hash: SHA1

On Thursday 16 September 2004 10:55 am, David Schontzler wrote:
> Well, I think that we'll probably want to combine some classes in a
> single file in some cases, but I'm sure we can set it up to combine
> files during build time. That said, one file per class should be
> fine.

I'm really dis-interested in the one file per class model, esp if it 
is going to be enforced by our tools. IMO, it makes it very easy to 
create code that's impossible to follow, and the number of "include 
this" statements at the top of the file can easily outnumber the 
amount of relevant code being written.

I think what I like much better is something like Python's package 
system where you can put classes anywhere you damn well please, but 
they are grouped into packages (in our case, namespaces), and that's 
where the file-system can help inform things by making directory 
names signficant. The import command allows you to import packages 
and packages have some sort of descriptor that tells the system where 
to get what it's looking for.

So my vote isn't necessarialy against one file per class in concept, 
but against a convention about it that gets enforced by tools and/or 
the script loader without any flexibility.


- -- 
Alex Russell
alex at burstlib.org   BD10 7AFC 87F6 63F9 1691 83FA 9884 3A15 AFC9 61B7
alex at netWindows.org F687 1964 1EF6 453E 9BD0 5148 A15D 1D43 AB92 9A46
Version: GnuPG v1.2.4 (Darwin)


More information about the NG-DHTML mailing list