Class: Qs::ErrorContext
- Inherits:
-
Object
- Object
- Qs::ErrorContext
- Defined in:
- lib/qs/error_handler.rb
Instance Attribute Summary collapse
-
#daemon_data ⇒ Object
readonly
Returns the value of attribute daemon_data.
-
#encoded_payload ⇒ Object
readonly
Returns the value of attribute encoded_payload.
-
#handler_class ⇒ Object
readonly
Returns the value of attribute handler_class.
-
#message ⇒ Object
readonly
Returns the value of attribute message.
-
#queue_name ⇒ Object
readonly
Returns the value of attribute queue_name.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(args) ⇒ ErrorContext
constructor
A new instance of ErrorContext.
Constructor Details
#initialize(args) ⇒ ErrorContext
Returns a new instance of ErrorContext.
37 38 39 40 41 42 43 |
# File 'lib/qs/error_handler.rb', line 37 def initialize(args) @daemon_data = args[:daemon_data] @queue_name = Queue::RedisKey.parse_name(args[:queue_redis_key].to_s) @encoded_payload = args[:encoded_payload] @message = args[:message] @handler_class = args[:handler_class] end |
Instance Attribute Details
#daemon_data ⇒ Object (readonly)
Returns the value of attribute daemon_data.
33 34 35 |
# File 'lib/qs/error_handler.rb', line 33 def daemon_data @daemon_data end |
#encoded_payload ⇒ Object (readonly)
Returns the value of attribute encoded_payload.
34 35 36 |
# File 'lib/qs/error_handler.rb', line 34 def encoded_payload @encoded_payload end |
#handler_class ⇒ Object (readonly)
Returns the value of attribute handler_class.
35 36 37 |
# File 'lib/qs/error_handler.rb', line 35 def handler_class @handler_class end |
#message ⇒ Object (readonly)
Returns the value of attribute message.
35 36 37 |
# File 'lib/qs/error_handler.rb', line 35 def @message end |
#queue_name ⇒ Object (readonly)
Returns the value of attribute queue_name.
34 35 36 |
# File 'lib/qs/error_handler.rb', line 34 def queue_name @queue_name end |
Instance Method Details
#==(other) ⇒ Object
45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/qs/error_handler.rb', line 45 def ==(other) if other.kind_of?(self.class) self.daemon_data == other.daemon_data && self.queue_name == other.queue_name && self.encoded_payload == other.encoded_payload && self. == other. && self.handler_class == other.handler_class else super end end |