On Jun 7, 2012, at 6:12 PM, Cliff Kachinske wrote:
> Does that mean there's only one instance of current for a running instance of
> Web2py? So if I do current.db, it could overwrite a current.db assigned in
> an earlier request?
No, it's unique to the current request (that's why it's called cu
Thanks, Jonathon,
Does that mean there's only one instance of current for a running instance
of Web2py? So if I do current.db, it could overwrite a current.db assigned
in an earlier request?
On Thursday, June 7, 2012 7:07:35 PM UTC-4, Jonathan Lundell wrote:
>
> On Jun 7, 2012, at 2:42 PM, Cli
On Jun 7, 2012, at 2:42 PM, Cliff Kachinske wrote:
> I don't have a good feel for the most efficient way to, for example, pass the
> db to a class method. I can think of three ways.
>
> - Pass it in when you call the method.
> - Pass it in when you initialize the class
> - Import current, do som
I'm just starting to use modules with classes for code commonality.
I don't have a good feel for the most efficient way to, for example, pass
the db to a class method. I can think of three ways.
- Pass it in when you call the method.
- Pass it in when you initialize the class
- Import current,
4 matches
Mail list logo