Class: Twilio::REST::Content::V2::ContentListResponse
- Inherits:
-
InstanceListResource
- Object
- InstanceListResource
- Twilio::REST::Content::V2::ContentListResponse
- Defined in:
- lib/twilio-ruby/rest/content/v2/content.rb
Instance Method Summary collapse
- #content ⇒ Object
- #headers ⇒ Object
-
#initialize(version, payload, key, limit = :unset) ⇒ ContentListResponse
constructor
A new instance of ContentListResponse.
- #status_code ⇒ Object
Constructor Details
#initialize(version, payload, key, limit = :unset) ⇒ ContentListResponse
Returns a new instance of ContentListResponse.
294 295 296 297 298 299 300 301 302 303 304 |
# File 'lib/twilio-ruby/rest/content/v2/content.rb', line 294 def initialize(version, payload, key, limit = :unset) data_list = payload.body[key] if limit != :unset data_list = data_list[0, limit] end @content = data_list.map do |data| ContentInstance.new(version, data) end @headers = payload.headers @status_code = payload.status_code end |
Instance Method Details
#content ⇒ Object
306 307 308 |
# File 'lib/twilio-ruby/rest/content/v2/content.rb', line 306 def content @content end |
#headers ⇒ Object
310 311 312 |
# File 'lib/twilio-ruby/rest/content/v2/content.rb', line 310 def headers @headers end |
#status_code ⇒ Object
314 315 316 |
# File 'lib/twilio-ruby/rest/content/v2/content.rb', line 314 def status_code @status_code end |