On Wednesday 20 August 2014 10:29:49 Anssi Kääriäinen wrote:
> On Wednesday, August 20, 2014 11:19:33 AM UTC+3, Russell Keith-Magee wrote:
> > 
> > This yields the following formal API for _meta:
> >  * get_fields(data, many_to_many, related, include_hidden,
> >                     include_parents)
> >  
> >  * @property data_fields 
> > 
> >  * @property many_to_many_fields 
> > 
> >  * @property related_objects 
> >  (=> get_fields(data=False, many_to_many=False, related=True,
> >                          include_hidden=False, include_parents=True)
> > 
> +1 if we also consider defining and documenting an useful set of field flags.

+1 Anssi.

>
> I wonder if a better name for the related category exists. My first
> instinct is that foreign key fields should match the related flag. Could it
> be made cleaner that these are relations defined on remote model? Maybe
> just remote_relations could work?
> 

Since this is a bikeshedding thread, I'll say that the name "related_objects" 
makes me itch a little as well -- mostly, because each of the objects returned 
by the property is not a related-object, but rather a manager of related-
objects.

I was considering "related_managers", but that is sort-of mixing the "what" 
with the "how", and also thinking about the possible Array(FK) fields, I prefer 
"related_collections".

Shai.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/2540029.o0OKDSAJdQ%40deblack.
For more options, visit https://groups.google.com/d/optout.

Reply via email to