Hi,

I'm working on a module which will eventually be CAD::Drawing

Currently, it is named <place where I store modules>::Drawing and the package 
is declared as simply "Drawing".

I've run into a wall with my original data structure and have seen a much more 
flexible and expandable way to do things, so I will be rebuilding the entire 
module and its children.

The sub-modules are currently stored under Drawing/*.pm and they all declare 
their packages as "Drawing".  These modules contain methods and helper 
functions/constants.  For example, Drawing/Manipulate.pm contains the 
functions Move, Copy (and lots of other goodies.)  It would not work as a 
standalone and is not intended to ever be use'd by main.  There is also a 
file Drawing/Defined.pm which exports a pile of constants, but these only get 
exported to Drawing.pm and never show up in main (as intended.)

I've seen the use of @ISA in perltoot, and it looks like this would work, but 
it does not seem like inheritance is really what I'm doing (since the 
sub-modules aren't really base classes (none of them have (or could have) 
constructors.))  If it didn't amount to so many lines, all of the functions 
could really be contained in one file (but this makes it hard to edit and 
navigate.)

Is this overloading of my own namespace the right way to go, or should I be 
using some more rigorous method?  I imagine that the entire distribution 
could eventually be rather complicated, so I'd like to start down the path to 
robustness with this next revamp.

Thanks,
Eric
-- 
"It is a mistake to allow any mechanical object to realize that you are in a 
hurry."
                                        --Ralph's Observation

Reply via email to