Class: DSP::ThreadsResponse

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

Overview

interface ThreadsResponse extends Response {

    body: {
        /** All threads. */
        threads: Thread[];
    };
}

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from DSPBase

#to_h, #to_json

Constructor Details

#initialize(initial_hash = nil) ⇒ ThreadsResponse

Returns a new instance of ThreadsResponse.



2671
2672
2673
2674
# File 'lib/dsp/dsp_protocol.rb', line 2671

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

Instance Attribute Details

#bodyObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def body
  @body
end

#commandObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def command
  @command
end

#messageObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def message
  @message
end

#request_seqObject

/** All threads. */

    threads: Thread[];
}


2669
2670
2671
# File 'lib/dsp/dsp_protocol.rb', line 2669

def request_seq
  @request_seq
end

#seqObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def seq
  @seq
end

#successObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def success
  @success
end

#typeObject

type: {



2665
2666
2667
# File 'lib/dsp/dsp_protocol.rb', line 2665

def type
  @type
end

Instance Method Details

#from_h!(value) ⇒ Object



2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
# File 'lib/dsp/dsp_protocol.rb', line 2676

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