After a more careful perusing and sifting of your response, I discovered
this helped my understanding a lot better:


>
> You can bring names into the package namespace, but the actual code will
> still run in the module where it is defined. For example, in
> PrintMe/PrintBase/__init__.py you can say
>    from PrintBase import Printbase
>
> Hmm. I'm not sure if this will work the way you want because of the name
> collisions. Using the sound example where the names are unique, suppose
> wavread.py includes a function read_wav(). Then in Formats/__init__.py
> you can say
>    from wavread import read_wav
>
> This imports the name read_wav into the Formats package namespace so
> other code will be able to say
>    from Sound.Formats import read_wav



This above seems to be closest to what I'm hoping to achieve ... I will try
this out and see how it goes.  Thanks again!


Andrew
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to