Class: Circuitry::Message
- Inherits:
-
Object
- Object
- Circuitry::Message
- Defined in:
- lib/circuitry/message.rb
Instance Attribute Summary collapse
-
#sqs_message ⇒ Object
readonly
Returns the value of attribute sqs_message.
Instance Method Summary collapse
- #body ⇒ Object
- #context ⇒ Object
- #id ⇒ Object
-
#initialize(sqs_message) ⇒ Message
constructor
A new instance of Message.
- #receipt_handle ⇒ Object
- #topic ⇒ Object
Constructor Details
#initialize(sqs_message) ⇒ Message
Returns a new instance of Message.
8 9 10 |
# File 'lib/circuitry/message.rb', line 8 def initialize() @sqs_message = end |
Instance Attribute Details
#sqs_message ⇒ Object (readonly)
Returns the value of attribute sqs_message.
6 7 8 |
# File 'lib/circuitry/message.rb', line 6 def @sqs_message end |
Instance Method Details
#body ⇒ Object
16 17 18 |
# File 'lib/circuitry/message.rb', line 16 def body @body ||= JSON.parse(context['Message'], quirks_mode: true) end |
#context ⇒ Object
12 13 14 |
# File 'lib/circuitry/message.rb', line 12 def context @context ||= JSON.parse(.body) end |
#id ⇒ Object
24 25 26 |
# File 'lib/circuitry/message.rb', line 24 def id . end |
#receipt_handle ⇒ Object
28 29 30 |
# File 'lib/circuitry/message.rb', line 28 def receipt_handle .receipt_handle end |