Class: DSP::CompletionsResponse
- Defined in:
- lib/dsp/dsp_protocol.rb
Overview
interface CompletionsResponse extends Response {
body: {
/** The possible completions for . */
targets: CompletionItem[];
};
}
Instance Attribute Summary collapse
-
#body ⇒ Object
type: {.
-
#command ⇒ Object
type: {.
-
#message ⇒ Object
type: {.
-
#request_seq ⇒ Object
/** The possible completions for .
-
#seq ⇒ Object
type: {.
-
#success ⇒ Object
type: {.
-
#type ⇒ Object
type: {.
Instance Method Summary collapse
- #from_h!(value) ⇒ Object
-
#initialize(initial_hash = nil) ⇒ CompletionsResponse
constructor
A new instance of CompletionsResponse.
Methods inherited from DSPBase
Constructor Details
#initialize(initial_hash = nil) ⇒ CompletionsResponse
Returns a new instance of CompletionsResponse.
3322 3323 3324 3325 |
# File 'lib/dsp/dsp_protocol.rb', line 3322 def initialize(initial_hash = nil) super @optional_method_names = %i[message] end |
Instance Attribute Details
#body ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def body @body end |
#command ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def command @command end |
#message ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def @message end |
#request_seq ⇒ Object
/** The possible completions for . */
targets: CompletionItem[];
}
3320 3321 3322 |
# File 'lib/dsp/dsp_protocol.rb', line 3320 def request_seq @request_seq end |
#seq ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def seq @seq end |
#success ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def success @success end |
#type ⇒ Object
type: {
3316 3317 3318 |
# File 'lib/dsp/dsp_protocol.rb', line 3316 def type @type end |
Instance Method Details
#from_h!(value) ⇒ Object
3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 |
# File 'lib/dsp/dsp_protocol.rb', line 3327 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. = value['message'] self.seq = value['seq'] self.type = value['type'] self end |