Module: ResourceSubscriber::Resourceful
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/resource_subscriber/resourceful.rb
Instance Attribute Summary collapse
-
#changes ⇒ Object
Returns the value of attribute changes.
-
#resource ⇒ Object
Returns the value of attribute resource.
Instance Method Summary collapse
Instance Attribute Details
#changes ⇒ Object
Returns the value of attribute changes.
5 6 7 |
# File 'lib/resource_subscriber/resourceful.rb', line 5 def changes @changes end |
#resource ⇒ Object
Returns the value of attribute resource.
5 6 7 |
# File 'lib/resource_subscriber/resourceful.rb', line 5 def resource @resource end |
Instance Method Details
#initialize(*args) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/resource_subscriber/resourceful.rb', line 7 def initialize(*args) super(*args) @resource = env["resource"] @changes = env["changes"] end |
#was_changed?(*args, **options) ⇒ Boolean
14 15 16 |
# File 'lib/resource_subscriber/resourceful.rb', line 14 def was_changed?(*args, **) @changes.was_changed?(*args, **) end |