use LanguageServer::Protocol::Transport::Io::*, Thread::Queue, RBS::AST::Comment use Steep::Services::CompletionProvider, Steep::Services::TypeNameCompletion use RBS::TypeName, RBS::Namespace module Steep module Server class InteractionWorker < BaseWorker include ChangeBuffer class ApplyChangeJob end class HoverJob attr_reader id: String attr_reader path: Pathname attr_reader line: Integer attr_reader column: Integer def initialize: (id: String, path: Pathname, line: Integer, column: Integer) -> void end class CompletionJob attr_reader id: String attr_reader path: Pathname attr_reader line: Integer attr_reader column: Integer attr_reader trigger: String def initialize: (id: String, path: Pathname, line: Integer, column: Integer, trigger: String) -> void end type job = ApplyChangeJob | HoverJob | CompletionJob module LSP = LanguageServer::Protocol attr_reader service: Services::TypeCheckService def initialize: (project: Project, reader: Reader, writer: Writer, ?queue: Queue) -> void def handle_job: (job) -> void type lsp_request = { id: String, method: String, params: untyped } def handle_request: (lsp_request) -> void def process_hover: (HoverJob job) -> untyped def process_completion: (CompletionJob job) -> untyped def format_completion_item_for_rbs: (Services::SignatureService, RBS::TypeName, CompletionJob job, String complete_text, Integer prefix_size) -> untyped def format_comment: (Comment? comment) -> untyped? def format_comments: (Array[RBS::AST::Comment] comments) -> untyped? def format_completion_item: (CompletionProvider::item item) -> untyped def method_type_to_snippet: (RBS::MethodType method_type) -> ::String def params_to_snippet: (RBS::Types::Function fun) -> String end end end