Class: VoiceML::OutgoingCallerIdList

Inherits:
Object
  • Object
show all
Includes:
Pageable
Defined in:
lib/voiceml/models/outgoing_caller_ids.rb

Overview

Paginated GET /OutgoingCallerIds response.

Constant Summary

Constants included from Pageable

Pageable::PAGE_FIELDS

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Pageable

#assign_page_fields

Constructor Details

#initialize(hash = {}) ⇒ OutgoingCallerIdList

Returns a new instance of OutgoingCallerIdList.



37
38
39
40
41
# File 'lib/voiceml/models/outgoing_caller_ids.rb', line 37

def initialize(hash = {})
  assign_page_fields(hash)
  @outgoing_caller_ids =
    (hash['outgoing_caller_ids'] || []).map { |o| OutgoingCallerId.from_hash(o) }
end

Instance Attribute Details

#outgoing_caller_idsObject (readonly)

Returns the value of attribute outgoing_caller_ids.



35
36
37
# File 'lib/voiceml/models/outgoing_caller_ids.rb', line 35

def outgoing_caller_ids
  @outgoing_caller_ids
end

Class Method Details

.from_hash(hash) ⇒ Object



43
44
45
# File 'lib/voiceml/models/outgoing_caller_ids.rb', line 43

def self.from_hash(hash)
  new(hash || {})
end