Class: Twilio::REST::Events::V1::SchemaListResponse

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

Instance Method Summary collapse

Constructor Details

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

Returns a new instance of SchemaListResponse.

Parameters:

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


174
175
176
177
178
179
180
# File 'lib/twilio-ruby/rest/events/v1/schema.rb', line 174

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

Instance Method Details

#headersObject



267
268
269
# File 'lib/twilio-ruby/rest/events/v1/schema.rb', line 267

def headers
  @headers
end

#schemaObject



263
264
265
# File 'lib/twilio-ruby/rest/events/v1/schema.rb', line 263

def schema
    @schema
end

#schema_instanceObject



182
183
184
# File 'lib/twilio-ruby/rest/events/v1/schema.rb', line 182

def schema_instance
    @instance
end

#status_codeObject



271
272
273
# File 'lib/twilio-ruby/rest/events/v1/schema.rb', line 271

def status_code
  @status_code
end