Module: MassiveRecord::ORM::AttributeMethods::ClassMethods
- Defined in:
- lib/massive_record/orm/attribute_methods.rb
Instance Method Summary collapse
- #attribute_methods_generated? ⇒ Boolean
- #attributes_protected_by_default ⇒ Object
- #define_attribute_methods ⇒ Object
- #undefine_attribute_methods(*args) ⇒ Object
Instance Method Details
#attribute_methods_generated? ⇒ Boolean
18 19 20 |
# File 'lib/massive_record/orm/attribute_methods.rb', line 18 def attribute_methods_generated? @attribute_methods_generated ||= false end |
#attributes_protected_by_default ⇒ Object
27 28 29 |
# File 'lib/massive_record/orm/attribute_methods.rb', line 27 def attributes_protected_by_default ['id', inheritance_attribute] end |
#define_attribute_methods ⇒ Object
13 14 15 16 |
# File 'lib/massive_record/orm/attribute_methods.rb', line 13 def define_attribute_methods super(known_attribute_names) @attribute_methods_generated = true end |
#undefine_attribute_methods(*args) ⇒ Object
22 23 24 25 |
# File 'lib/massive_record/orm/attribute_methods.rb', line 22 def undefine_attribute_methods(*args) super @attribute_methods_generated = false end |