Class: DjiMqttConnect::Thing::Product::StateReplyMessage
- Inherits:
-
Message
- Object
- Dry::Struct
- Message
- DjiMqttConnect::Thing::Product::StateReplyMessage
- Defined in:
- lib/dji_mqtt_connect/messages/thing/product/state_reply_message.rb
Class Method Summary collapse
-
.build_for(events_message, result: 0) ⇒ Object
a result of 0 means we approve of this action.
Instance Method Summary collapse
Methods inherited from Message
current_timestamp, generate_bid, generate_tid, #to_s
Class Method Details
.build_for(events_message, result: 0) ⇒ Object
a result of 0 means we approve of this action
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/dji_mqtt_connect/messages/thing/product/state_reply_message.rb', line 7 def self.build_for(, result: 0) new( tid: .tid, bid: .bid, timestamp: , data: { result: result } ) end |
Instance Method Details
#humanized_summary ⇒ Object
31 32 33 |
# File 'lib/dji_mqtt_connect/messages/thing/product/state_reply_message.rb', line 31 def humanized_summary Translations.thing_product_state_reply_summary(**humanized_summary_interpolation) end |
#humanized_summary_interpolation ⇒ Object
35 36 37 |
# File 'lib/dji_mqtt_connect/messages/thing/product/state_reply_message.rb', line 35 def humanized_summary_interpolation data.to_h end |