Module: CarrierWave::Workers::Base
- Included in:
- ProcessAssetMixin, StoreAssetMixin
- Defined in:
- lib/backgrounder/workers/base.rb
Instance Attribute Summary collapse
-
#column ⇒ Object
Returns the value of attribute column.
-
#id ⇒ Object
Returns the value of attribute id.
-
#klass ⇒ Object
Returns the value of attribute klass.
-
#record ⇒ Object
Returns the value of attribute record.
Instance Method Summary collapse
Instance Attribute Details
#column ⇒ Object
Returns the value of attribute column.
6 7 8 |
# File 'lib/backgrounder/workers/base.rb', line 6 def column @column end |
#id ⇒ Object
Returns the value of attribute id.
6 7 8 |
# File 'lib/backgrounder/workers/base.rb', line 6 def id @id end |
#klass ⇒ Object
Returns the value of attribute klass.
6 7 8 |
# File 'lib/backgrounder/workers/base.rb', line 6 def klass @klass end |
#record ⇒ Object
Returns the value of attribute record.
6 7 8 |
# File 'lib/backgrounder/workers/base.rb', line 6 def record @record end |
Instance Method Details
#initialize(*args) ⇒ Object
8 9 10 11 |
# File 'lib/backgrounder/workers/base.rb', line 8 def initialize(*args) super(*args) unless self.class.superclass == Object set_args(*args) if args.present? end |
#perform(*args) ⇒ Object
13 14 15 16 17 |
# File 'lib/backgrounder/workers/base.rb', line 13 def perform(*args) set_args(*args) if args.present? self.record = constantized_resource.find id rescue *not_found_errors end |