Class: Hyrax::Listeners::FileSetLifecycleListener
- Inherits:
-
Object
- Object
- Hyrax::Listeners::FileSetLifecycleListener
- Defined in:
- app/services/hyrax/listeners/file_set_lifecycle_listener.rb
Overview
Listens for events related to Hydra Works FileSets
Instance Method Summary collapse
-
#on_file_set_attached(event) ⇒ void
Called when ‘file.set.attached’ event is published.
-
#on_file_set_restored(event) ⇒ void
Called when ‘file.set.restored’ event is published.
Instance Method Details
#on_file_set_attached(event) ⇒ void
This method returns an undefined value.
Called when ‘file.set.attached’ event is published
12 13 14 |
# File 'app/services/hyrax/listeners/file_set_lifecycle_listener.rb', line 12 def on_file_set_attached(event) FileSetAttachedEventJob.perform_later(event[:file_set], event[:user]) end |
#on_file_set_restored(event) ⇒ void
This method returns an undefined value.
Called when ‘file.set.restored’ event is published
20 21 22 23 |
# File 'app/services/hyrax/listeners/file_set_lifecycle_listener.rb', line 20 def on_file_set_restored(event) ContentRestoredVersionEventJob .perform_later(event[:file_set], event[:user], event[:revision]) end |