On Feb 9, 1:44 pm, "Mislav Marohnić" <[EMAIL PROTECTED]>
wrote:
> On Feb 9, 2008 7:35 PM, Glenn Rempe <[EMAIL PROTECTED]> wrote:
>
> > In other words, no
> > method signature is easily available since these are method_missing
> > dynamic methods.  How can we improve this?
>
> With better documentation on the class level. I don't think there is any
> other way (except for hacking RDoc maybe with a custom feature, good luck
> with that).

I agree.  I wouldn't want to suggest going near rdoc for this one.

> I strongly oppose your suggestion #2; it's unintuitive and hard to implement
> (e.g. what if the user has a "conditions" attribute).

Hmmm...  Playing devils advocate I would say that not having it there
is counterintuitive since the current docs, and my experience with all
other types of finders, seem to imply to me that it should work.  Are
there other find methods that don't except :conditions except these
two?  :conditions is something that should work across all finders to
be truly consistent.  Is the consistency with other find methods in
the API worth ignoring the edge case where the model has a conditions
attribute?  I have no doubt it may be hard to implement, but the
question I am posing for the moment is if it is the right thing to do,
not how hard it is.  I hear your 'no' vote though.  :-)


> About #3: better documentation is definitely a way to go. As you were
> surprised yourself and thinking others may be, write a doc patch to stress
> out how conditions are not working -- the name of the finder is a condition
> itself.

I will see if I can work up a documentation patch that clarifies
somewhat while the collective rails mind thinks about whether any of
my other idea has merit. :-)


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

Reply via email to