方法
屬性
[R] | matchers | |
[R] | attribute_names | |
[R] | model | |
[R] | name |
類別公開方法
match(model, name) 連結
new(model, method_name) 連結
# File activerecord/lib/active_record/dynamic_matchers.rb, line 52 def initialize(model, method_name) @model = model @name = method_name.to_s @attribute_names = @name.match(self.class.pattern)[1].split("_and_") @attribute_names.map! { |name| @model.attribute_aliases[name] || name } end