how I can get the has_many associations of a model?
For example if I have this class:
class A < ActiveRecord::Base has_many B has_many C end <
Found the solutions:
def self.get_macros(macro) res = Array.new self.reflections.each do |k,v| res << k if v.macro == macro.to_sym end return res end