Class: SMSBox::WebsendResponse
- Inherits:
-
XMLResponse
- Object
- XMLResponse
- SMSBox::WebsendResponse
- Defined in:
- lib/sms_box/websend_response.rb
Instance Attribute Summary collapse
-
#receiver_status ⇒ Object
Returns the value of attribute receiver_status.
Attributes inherited from XMLResponse
#command, #command_data, #error, #request, #requestUid
Instance Method Summary collapse
- #command_data=(command_nodeset) ⇒ Object
-
#initialize ⇒ WebsendResponse
constructor
A new instance of WebsendResponse.
Methods inherited from XMLResponse
#error?, from_xml, instantize, #success?
Constructor Details
#initialize ⇒ WebsendResponse
Returns a new instance of WebsendResponse.
6 7 8 9 |
# File 'lib/sms_box/websend_response.rb', line 6 def initialize super self.receiver_status = [] end |
Instance Attribute Details
#receiver_status ⇒ Object
Returns the value of attribute receiver_status.
4 5 6 |
# File 'lib/sms_box/websend_response.rb', line 4 def receiver_status @receiver_status end |
Instance Method Details
#command_data=(command_nodeset) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/sms_box/websend_response.rb', line 11 def command_data=(command_nodeset) super self.receiver_status = command_nodeset.xpath('receiver').map do |receiver| { :receiver => receiver.text, :status => receiver[:status] } end end |