Class: Twilio::REST::Conversations::V1::RoleListResponse

Inherits:
InstanceListResource show all
Defined in:
lib/twilio-ruby/rest/conversations/v1/role.rb,
lib/twilio-ruby/rest/conversations/v1/role.rb

Instance Method Summary collapse

Constructor Details

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

Returns a new instance of RoleListResponse.

Parameters:

  • instance (Array<RoleInstance>)
  • headers (Hash{String => Object})
  • status_code (Integer)


429
430
431
432
433
434
435
# File 'lib/twilio-ruby/rest/conversations/v1/role.rb', line 429

def initialize(version, payload, key)
   @role_instance = payload.body[key].map do |data|
    RoleInstance.new(version, data)
   end
   @headers = payload.headers
   @status_code = payload.status_code
end

Instance Method Details

#headersObject



522
523
524
# File 'lib/twilio-ruby/rest/conversations/v1/role.rb', line 522

def headers
  @headers
end

#roleObject



518
519
520
# File 'lib/twilio-ruby/rest/conversations/v1/role.rb', line 518

def role
    @role
end

#role_instanceObject



437
438
439
# File 'lib/twilio-ruby/rest/conversations/v1/role.rb', line 437

def role_instance
    @instance
end

#status_codeObject



526
527
528
# File 'lib/twilio-ruby/rest/conversations/v1/role.rb', line 526

def status_code
  @status_code
end