> it also accepts "cls" as a keyword argument which is used as the base
> class:
>
>         Base = declarative_base(..., cls=MyMixin)
>
> you can also add a mixin to any class in Python like:
>
>         Base = declarative_base(...)
>         MyBase = type("MyBase", (Base, MyMixin), {})

Thanks!  Both are good to know and better than mixing each time I
create a class.  I didn't know about the second use of type()... that
could be very useful.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" 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/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to