structuring a package?

James Mills prologic at shortcircuit.net.au
Mon Jan 5 01:27:37 CET 2009


On Mon, Jan 5, 2009 at 10:17 AM, Torsten Mohr <tmohr at s.netic.de> wrote:
> It looks natural to me to write in a code that uses the package:
>
> import graphic
> import graphic.square
> import graphic.circle
>
> That way i'd have to structure the code like this:
>
> graphic/
>  __init__,py  (GraphicObject)
>  square.py (Square)
>  circle.py (Circle)
>
> Does that make sense like this?

This seems perfectly acceptable.

cheers
James



More information about the Python-list mailing list