On 11/19/06, Jorge Godoy <[EMAIL PROTECTED]> wrote:
> > class Book (Entity):
> >     class turboentity:
> >         tablename = "book"
> >         act_as = "List" # declare "act_as" in metadata
>
> Personally I prefer the second option.  It is more readable and lets your
> intentions clearer.

Rails uses Ruby mixins for this, which do end up looking a lot like
the above approach, but that's the standard Ruby idiom (since Ruby
doesn't support multiple inheritance).

I'd very slightly prefer a MI approach (assuming the usual issues with
MI can be worked around), if for no other reason than it's more
idiomatic in Python, and it's more discoverable and explorable from an
interactive shell (one of my complaints with SQLObject right now).

-- 
Tim Lesher <[EMAIL PROTECTED]>

--~--~---------~--~----~------------~-------~--~----~
 You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to