Module: Acfs::Resource::Dirty
- Extended by:
- ActiveSupport::Concern
- Includes:
- ActiveModel::Dirty
- Included in:
- Acfs::Resource
- Defined in:
- lib/acfs/resource/dirty.rb
Overview
Thin wrapper around ActiveModel::Dirty
Instance Method Summary collapse
- #loaded! ⇒ Object private
- #reset_changes ⇒ Object private
- #save!(**kwargs) ⇒ Object private
- #write_raw_attribute(name, value, opts = {}) ⇒ Object private
Instance Method Details
#loaded! ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
25 26 27 28 |
# File 'lib/acfs/resource/dirty.rb', line 25 def loaded! reset_changes super end |
#reset_changes ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
13 14 15 |
# File 'lib/acfs/resource/dirty.rb', line 13 def reset_changes clear_changes_information end |
#save!(**kwargs) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
19 20 21 |
# File 'lib/acfs/resource/dirty.rb', line 19 def save!(**kwargs) super.tap {|_| changes_applied } end |
#write_raw_attribute(name, value, opts = {}) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
32 33 34 35 |
# File 'lib/acfs/resource/dirty.rb', line 32 def write_raw_attribute(name, value, opts = {}) attribute_will_change!(name) if opts[:change].nil? || opts[:change] super end |