Interdependent modules?

Derek Parnell derek at nomail.afraid.org
Mon Jun 19 23:54:30 PDT 2006


On Tue, 20 Jun 2006 06:29:38 +0000 (UTC), Jeremy Gibson wrote:

>>Just throwing out an idea here, but if two modules are dependant on each
>>other, why not combine them into a single module?
> 
> Two reasons, although I'll admit that I hadn't thought of that. ;-)
> 
> First and foremost is length: my object class are heavyweight classes which
> represent objects existing in 3D; my data classes are lightweight classes for
> storing simple information (they'd be justifiable as structs, really).  Second
> is specialisation: the data classes are very, very simple and generally
> applicable, but the object classes are the root of a whole hierarchy of classes,
> and have (rather, will have) a lot of physics and the like that isn't really
> relevant to most other modules.
> 
> I suppose the easiest way to describe the difference is by saying that objects
> are of actual interest to the end user of the program, while the data classes
> are only of use to the programmer: I'd prefer to keep those different concepts
> distinct to make things a little more manageable on my end.

In that case, it sounds like even further refactoring is required to
isolate those things that are only dependant on the module that contains
them.

-- 
Derek
(skype: derek.j.parnell)
Melbourne, Australia
"Down with mediocrity!"
20/06/2006 4:53:37 PM



More information about the Digitalmars-d-learn mailing list