Class: SmsBroker::Client::Response::VoiceSuccess

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

Direct Known Subclasses

NexmoVoiceSuccess

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(service, response, serialized) ⇒ VoiceSuccess

Returns a new instance of VoiceSuccess.



9
10
11
12
13
# File 'lib/sms_broker/client/response/voice_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/voice_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/voice_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/voice_success.rb', line 5

def service
  @service
end

Instance Method Details

#call_idObject



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

def call_id
  serialized[:call_id]
end

#success?Boolean

Returns:

  • (Boolean)


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

def success?
  true
end

#toObject



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

def to
  serialized[:to]
end