List of methods derived from associations?


I’m at this point essentially a Rails hobbiest: entranced, enthralled,
immersed but not writing Rails apps commercially. I am sure my question
has been asked and answered but I searched and couldn’t find it, so…

Is there somewhere a list of methods that become available via
associations? I was doing a project with acts_as_tree and was struggling
with a breadcrumb navigation. Trying to do some nonsense with a
recursive function climbing up the tree via “parent”. I finally stumbled
across “ancestors” and it was a snap. But I didn’t know about
“ancestors”. Is there a resource somewhere that spells out what you “get
for free” from the common associations such as has_many and acts_as_tree
and has_and_belongs_to_many?

Thanks a million.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs