Class: Twilio::REST::Insights::V1::ConferenceContext::ConferenceParticipantPageMetadata

Inherits:
PageMetadata
  • Object
show all
Defined in:
lib/twilio-ruby/rest/insights/v1/conference/conference_participant.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) ⇒ ConferenceParticipantPageMetadata

Returns a new instance of ConferenceParticipantPageMetadata.



364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 364

def initialize(version, response, solution, limit)
    super(version, response)
    @conference_participant_page = []
    @limit = limit
    key = get_key(response.body)
    records = 0
    while( limit != :unset && records < limit )
        @conference_participant_page << ConferenceParticipantListResponse.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

#conference_participant_pageObject (readonly)

Returns the value of attribute conference_participant_page.



362
363
364
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 362

def conference_participant_page
  @conference_participant_page
end

Instance Method Details

#eachObject



380
381
382
383
384
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 380

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

#to_sObject



386
387
388
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 386

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