[Tutor] howto keep a program organised?

Rob Vogel robvog at gmail.com
Mon Sep 11 15:27:56 CEST 2006


Thanks for the info.
I will use a module.

Regards,
Rob



On 9/11/06, Alan Gauld <alan.gauld at btinternet.com> wrote:
> > The functions do not share variables, I don't use global vars, and I
> > don't need a new instance.
>
> In that case you don't need a class.
> A module should do all you need by providing a common namespace
> for your functions.
>
> > So in my case the only use of a class would be that all related usb
> > code will be grouped together, even though I do not need any of the
> > Class special abilities, as far as I understand.
>
> A module groups code together nicely, if the code doesn't share data
> and you don't create multiple instances there is no need for a class.
>
> Alan G.
>
> _______________________________________________
> Tutor maillist  -  Tutor at python.org
> http://mail.python.org/mailman/listinfo/tutor
>


More information about the Tutor mailing list