Class: DSP::VariablesResponse

Inherits:
DSPBase
  • Object
show all
Defined in:
lib/dsp/dsp_protocol.rb

Overview

interface VariablesResponse extends Response {

    body: {
        /** All (or a range) of variables for the given variable reference. */
        variables: Variable[];
    };
}

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DSPBase

#to_h, #to_json

Constructor Details

#initialize(initial_hash = nil) ⇒ VariablesResponse

Returns a new instance of VariablesResponse.



2438
2439
2440
2441
# File 'lib/dsp/dsp_protocol.rb', line 2438

def initialize(initial_hash = nil)
  super
  @optional_method_names = %i[message]
end

Instance Attribute Details

#bodyObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def body
  @body
end

#commandObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def command
  @command
end

#messageObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def message
  @message
end

#request_seqObject

/** All (or a range) of variables for the given variable reference. */

    variables: Variable[];
}


2436
2437
2438
# File 'lib/dsp/dsp_protocol.rb', line 2436

def request_seq
  @request_seq
end

#seqObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def seq
  @seq
end

#successObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def success
  @success
end

#typeObject

type: {



2432
2433
2434
# File 'lib/dsp/dsp_protocol.rb', line 2432

def type
  @type
end

Instance Method Details

#from_h!(value) ⇒ Object



2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
# File 'lib/dsp/dsp_protocol.rb', line 2443

def from_h!(value)
  value = {} if value.nil?
  self.body = value['body'] # Unknown type
  self.request_seq = value['request_seq']
  self.success = value['success'] # Unknown type
  self.command = value['command']
  self.message = value['message']
  self.seq = value['seq']
  self.type = value['type']
  self
end