Class: SidekiqRemappableErrors::Config
- Inherits:
-
Object
- Object
- SidekiqRemappableErrors::Config
- Defined in:
- lib/sidekiq_remappable_errors/config.rb
Instance Attribute Summary collapse
-
#remapped_error_class ⇒ Object
Returns the value of attribute remapped_error_class.
Instance Method Summary collapse
-
#initialize(remapped_error_class: RemappedError) ⇒ Config
constructor
A new instance of Config.
- #validate! ⇒ Object
Constructor Details
permalink #initialize(remapped_error_class: RemappedError) ⇒ Config
Returns a new instance of Config.
5 6 7 |
# File 'lib/sidekiq_remappable_errors/config.rb', line 5 def initialize(remapped_error_class: RemappedError) self.remapped_error_class = remapped_error_class end |
Instance Attribute Details
permalink #remapped_error_class ⇒ Object
Returns the value of attribute remapped_error_class.
8 9 10 |
# File 'lib/sidekiq_remappable_errors/config.rb', line 8 def remapped_error_class @remapped_error_class end |
Instance Method Details
permalink #validate! ⇒ Object
10 11 12 13 14 |
# File 'lib/sidekiq_remappable_errors/config.rb', line 10 def validate! return true if remapped_error_class <= Exception raise InvalidConfigError, "'remapped_error_class' must be an Exception" end |