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.



356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 356

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.



354
355
356
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 354

def conference_participant_page
  @conference_participant_page
end

Instance Method Details

#eachObject



372
373
374
375
376
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 372

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

#to_sObject



378
379
380
# File 'lib/twilio-ruby/rest/insights/v1/conference/conference_participant.rb', line 378

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