Class: Twilio::REST::Pricing::V1::PhoneNumberListResponse
- Inherits:
-
InstanceListResource
- Object
- InstanceListResource
- Twilio::REST::Pricing::V1::PhoneNumberListResponse
- Defined in:
- lib/twilio-ruby/rest/pricing/v1/phone_number.rb
Instance Method Summary collapse
- #headers ⇒ Object
-
#initialize(version, payload, key, limit = :unset) ⇒ PhoneNumberListResponse
constructor
A new instance of PhoneNumberListResponse.
- #phone_number ⇒ Object
- #status_code ⇒ Object
Constructor Details
#initialize(version, payload, key, limit = :unset) ⇒ PhoneNumberListResponse
Returns a new instance of PhoneNumberListResponse.
121 122 123 124 125 126 127 128 129 130 131 |
# File 'lib/twilio-ruby/rest/pricing/v1/phone_number.rb', line 121 def initialize(version, payload, key, limit = :unset) data_list = payload.body[key] if limit != :unset data_list = data_list[0, limit] end @phone_number = data_list.map do |data| PhoneNumberInstance.new(version, data) end @headers = payload.headers @status_code = payload.status_code end |
Instance Method Details
#headers ⇒ Object
137 138 139 |
# File 'lib/twilio-ruby/rest/pricing/v1/phone_number.rb', line 137 def headers @headers end |
#phone_number ⇒ Object
133 134 135 |
# File 'lib/twilio-ruby/rest/pricing/v1/phone_number.rb', line 133 def phone_number @phone_number end |
#status_code ⇒ Object
141 142 143 |
# File 'lib/twilio-ruby/rest/pricing/v1/phone_number.rb', line 141 def status_code @status_code end |