Class: SmsBroker::Client::Response::MessageStatusSuccess

Inherits:
Object
  • Object
show all
Defined in:
lib/sms_broker/client/response/message_status_success.rb

Direct Known Subclasses

OpenMarket::MessageStatusSuccess

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(service, response, serialized) ⇒ MessageStatusSuccess

Returns a new instance of MessageStatusSuccess.



9
10
11
12
13
# File 'lib/sms_broker/client/response/message_status_success.rb', line 9

def initialize(service, response, serialized)
  @raw = response
  @service = service
  @serialized = serialized
end

Instance Attribute Details

#rawObject (readonly)

Returns the value of attribute raw.



5
6
7
# File 'lib/sms_broker/client/response/message_status_success.rb', line 5

def raw
  @raw
end

#serializedObject (readonly)

Returns the value of attribute serialized.



5
6
7
# File 'lib/sms_broker/client/response/message_status_success.rb', line 5

def serialized
  @serialized
end

#serviceObject (readonly)

Returns the value of attribute service.



5
6
7
# File 'lib/sms_broker/client/response/message_status_success.rb', line 5

def service
  @service
end

Instance Method Details

#delivery_dateObject



27
28
29
# File 'lib/sms_broker/client/response/message_status_success.rb', line 27

def delivery_date
  serialized[:delivery_date]
end

#message_idObject



19
20
21
# File 'lib/sms_broker/client/response/message_status_success.rb', line 19

def message_id
  serialized[:message_id]
end

#statusObject



35
36
37
# File 'lib/sms_broker/client/response/message_status_success.rb', line 35

def status
  serialized[:status]
end

#status_codeObject



31
32
33
# File 'lib/sms_broker/client/response/message_status_success.rb', line 31

def status_code
  serialized[:status_code]
end

#success?Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/sms_broker/client/response/message_status_success.rb', line 15

def success?
  true
end

#toObject



23
24
25
# File 'lib/sms_broker/client/response/message_status_success.rb', line 23

def to
  serialized[:to]
end