Class: Twilio::REST::Content::V1::LegacyContentListResponse

Inherits:
InstanceListResource show all
Defined in:
lib/twilio-ruby/rest/content/v1/legacy_content.rb

Instance Method Summary collapse

Constructor Details

#initialize(version, payload, key, limit = :unset) ⇒ LegacyContentListResponse

Returns a new instance of LegacyContentListResponse.

Parameters:



216
217
218
219
220
221
222
223
224
225
226
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 216

def initialize(version, payload, key, limit = :unset)
  data_list = payload.body[key]
  if limit != :unset
    data_list = data_list[0, limit]
  end
  @legacy_content = data_list.map do |data|
    LegacyContentInstance.new(version, data)
  end
  @headers = payload.headers
  @status_code = payload.status_code
end

Instance Method Details

#headersObject



232
233
234
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 232

def headers
  @headers
end

#legacy_contentObject



228
229
230
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 228

def legacy_content
    @legacy_content
end

#status_codeObject



236
237
238
# File 'lib/twilio-ruby/rest/content/v1/legacy_content.rb', line 236

def status_code
  @status_code
end