Class: SDM::NodeDeleteResponse

Inherits:
Object
  • Object
show all
Defined in:
lib/models/porcelain.rb

Overview

NodeDeleteResponse returns information about a Node that was deleted.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(meta: nil, rate_limit: nil) ⇒ NodeDeleteResponse

Returns a new instance of NodeDeleteResponse.



8345
8346
8347
8348
8349
8350
8351
# File 'lib/models/porcelain.rb', line 8345

def initialize(
  meta: nil,
  rate_limit: nil
)
  @meta = meta == nil ? nil : meta
  @rate_limit = rate_limit == nil ? nil : rate_limit
end

Instance Attribute Details

#metaObject

Reserved for future use.



8341
8342
8343
# File 'lib/models/porcelain.rb', line 8341

def meta
  @meta
end

#rate_limitObject

Rate limit information.



8343
8344
8345
# File 'lib/models/porcelain.rb', line 8343

def rate_limit
  @rate_limit
end

Instance Method Details

#to_json(options = {}) ⇒ Object



8353
8354
8355
8356
8357
8358
8359
# File 'lib/models/porcelain.rb', line 8353

def to_json(options = {})
  hash = {}
  self.instance_variables.each do |var|
    hash[var.id2name.delete_prefix("@")] = self.instance_variable_get var
  end
  hash.to_json
end