module ActiveRecord::AttributeMethods::Write::ClassMethods

Protected Instance Methods

define_method_attribute=(name) Show source

See define_method_attribute in read.rb for an explanation of this code.

# File activerecord/lib/active_record/attribute_methods/write.rb, line 31
def define_method_attribute=(name)
  method = WriterMethodCache[name]
  generated_attribute_methods.module_eval {
    define_method "#{name}=", method
  }
end

© 2004–2016 David Heinemeier Hansson
Licensed under the MIT License.