Class: Twilio::REST::Video::V1::RecordingSettingsPageMetadata

Inherits:
PageMetadata
  • Object
show all
Defined in:
lib/twilio-ruby/rest/video/v1/recording_settings.rb

Constant Summary

Constants inherited from PageMetadata

PageMetadata::META_KEYS

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from PageMetadata

#get_key, #next_page, #next_page_url, #previous_page, #previous_page_url, #process_response

Constructor Details

#initialize(version, response, solution, limit) ⇒ RecordingSettingsPageMetadata

Returns a new instance of RecordingSettingsPageMetadata.



283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
# File 'lib/twilio-ruby/rest/video/v1/recording_settings.rb', line 283

def initialize(version, response, solution, limit)
    super(version, response)
    @recording_settings_page = []
    @limit = limit
    key = get_key(response.body)
    records = 0
    while( limit != :unset && records < limit )
        @recording_settings_page << RecordingSettingsListResponse.new(version, @payload, key, limit - records)
        @payload = self.next_page
        break unless @payload
        records += @payload.body[key].size
    end
    # Path Solution
    @solution = solution
end

Instance Attribute Details

#recording_settings_pageObject (readonly)

Returns the value of attribute recording_settings_page.



281
282
283
# File 'lib/twilio-ruby/rest/video/v1/recording_settings.rb', line 281

def recording_settings_page
  @recording_settings_page
end

Instance Method Details

#eachObject



299
300
301
302
303
# File 'lib/twilio-ruby/rest/video/v1/recording_settings.rb', line 299

def each
    @recording_settings_page.each do |record|
      yield record
    end
end

#to_sObject



305
306
307
# File 'lib/twilio-ruby/rest/video/v1/recording_settings.rb', line 305

def to_s
  '<Twilio::REST::Video::V1PageMetadata>';
end