Class: RubyLsp::Job
Overview
A request that will sit in the queue until it’s executed
Instance Attribute Summary collapse
-
#cancelled ⇒ Object
readonly
Returns the value of attribute cancelled.
-
#request ⇒ Object
readonly
Returns the value of attribute request.
Instance Method Summary collapse
- #cancel ⇒ Object
-
#initialize(request:, cancelled:) ⇒ Job
constructor
A new instance of Job.
Constructor Details
#initialize(request:, cancelled:) ⇒ Job
Returns a new instance of Job.
67 68 69 70 |
# File 'lib/ruby_lsp/utils.rb', line 67 def initialize(request:, cancelled:) @request = request @cancelled = cancelled end |
Instance Attribute Details
#cancelled ⇒ Object (readonly)
Returns the value of attribute cancelled.
64 65 66 |
# File 'lib/ruby_lsp/utils.rb', line 64 def cancelled @cancelled end |
#request ⇒ Object (readonly)
Returns the value of attribute request.
61 62 63 |
# File 'lib/ruby_lsp/utils.rb', line 61 def request @request end |
Instance Method Details
#cancel ⇒ Object
73 74 75 |
# File 'lib/ruby_lsp/utils.rb', line 73 def cancel @cancelled = true end |