Module INTERNAL.Server

module TYPES : sig ... end
include module type of TYPES with type config = TYPES.config and type params = TYPES.params and type sub_state = TYPES.sub_state and type pending_tasks = TYPES.pending_tasks and type registry = TYPES.registry and type state = TYPES.state and type exit_status = TYPES.exit_status and type 'a error = 'a TYPES.error
type config = TYPES.config = {
  1. project_layout : Superbol_project__.Project.TYPES.layout;
  2. cache_config : Cobol_lsp__.Lsp_project_cache.TYPES.config;
  3. enable_client_configs : bool;
  4. force_syntax_diagnostics : bool;
}
type params = TYPES.params = {
  1. config : config;
  2. root_uri : Lsp.Types.DocumentUri.t option;
  3. workspace_folders : Lsp.Types.DocumentUri.t list;
  4. with_semantic_tokens : bool;
  5. with_client_config_watcher : bool;
  6. with_client_file_watcher : bool;
}
type registry = TYPES.registry = {
  1. projects : Cobol_lsp__.Lsp_project.SET.t;
  2. docs : Cobol_lsp__.Lsp_document.TYPES.document Stdlib__Map.Make(Lsp.Uri).t;
  3. indirect_diags : Lsp.Types.Diagnostic.t list Stdlib__Map.Make(Lsp.Uri).t Stdlib__Map.Make(Lsp.Uri).t;
  4. pending_tasks : pending_tasks;
  5. sub_state : sub_state;
  6. params : params;
}
and sub_state = TYPES.sub_state
and pending_tasks = TYPES.pending_tasks
type state = TYPES.state =
  1. | NotInitialized of config
  2. | Initialized of params
  3. | Running of registry
  4. | ShuttingDown
  5. | Exit of exit_status
and exit_status = TYPES.exit_status
type 'a error = 'a TYPES.error =
  1. | InvalidStatus of state
  2. | UnhandledRequest of 'a Lsp.Client_request.t
  3. | UnknownRequest of string
exception Document_not_found of Lsp.Types.TextDocumentIdentifier.t
type t = registry
val init : params:params -> t
val on_change_workspace_folders : Lsp.Types.DidChangeWorkspaceFoldersParams.t -> t -> t
val did_open : Lsp.Types.DidOpenTextDocumentParams.t -> t -> t

Copybook detection is performed via project configuration (see Lsp_project.detect_copybook).

val did_change : Lsp.Types.DidChangeTextDocumentParams.t -> t -> t
val did_close : Lsp.Types.DidCloseTextDocumentParams.t -> t -> t
val find_document : Lsp.Types.TextDocumentIdentifier.t -> t -> Cobol_lsp__.Lsp_document.TYPES.document
val jsonrpc_of_error : 'a error -> string -> Jsonrpc.Response.Error.t
val on_response : int -> Lsp.Import.Json.t -> t -> t
val on_client_config_changes : ?changes:Yojson.Safe.t -> t -> t
val on_watched_file_changes : Lsp.Types.FileEvent.t list -> t -> t
val on_write_project_config_command : ?uri:Lsp.Uri.t -> t -> t
val get_project_config_command : Lsp.Uri.t -> t -> Yojson.Safe.t
val save_project_caches : t -> unit

Note: May only raise Jsonrpc.Response.Error.E