On Fri, 2008-02-22 at 16:49 -0800, Carl wrote:
> Hi there,
> 
> I don't find a solution to this problem even if it sounds quite simple
> to me. I want to inspect a model, that means a class derived from
> django.db.models.Model in order to get it's fields and their types -
> that's all!

Look at the _meta attribute on the model. It's an instance of
django.db.models.options.Options. Note that _meta is part of the
internal API and intentionally isn't documented (we don't want to commit
to it being stable for all time). However, it's mostly stable and we
will, over time, expose some of the more useful bits as public API.

Malcolm

-- 
Telepath required. You know where to apply... 
http://www.pointy-stick.com/blog/


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

Reply via email to