Re: sharing objects between classes

2008-01-28 Thread gherzig
> Diez B. Roggisch a écrit : >> Gerardo Herzig wrote: >> >>> Hi all. Im wondering the way to share a database connection between >>> some >>> classes: >>> >>> So far, i came up with a simple class schema, where each class means >>> each different relation, i mean i have the follow classes >>> >>> c

Re: sharing objects between classes

2008-01-28 Thread Bruno Desthuilliers
Diez B. Roggisch a écrit : > Gerardo Herzig wrote: > >> Hi all. Im wondering the way to share a database connection between some >> classes: >> >> So far, i came up with a simple class schema, where each class means >> each different relation, i mean i have the follow classes >> >> class Database(

Re: sharing objects between classes

2008-01-28 Thread Diez B. Roggisch
Gerardo Herzig wrote: > Hi all. Im wondering the way to share a database connection between some > classes: > > So far, i came up with a simple class schema, where each class means > each different relation, i mean i have the follow classes > > class Database(object): > ## make the connection

sharing objects between classes

2008-01-28 Thread Gerardo Herzig
Hi all. Im wondering the way to share a database connection between some classes: So far, i came up with a simple class schema, where each class means each different relation, i mean i have the follow classes class Database(object): ## make the connection self.conn = make_conn() class