diff options
author | Aleksey Kladov <[email protected]> | 2021-04-06 12:16:35 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2021-04-06 13:45:31 +0100 |
commit | 8fe20b19d4702fc6d6933c31abddc8539d2581f0 (patch) | |
tree | 8aca2a3aa2b059bb47cc235b1b557d4b4de93a24 /editors/code/src/lsp_ext.ts | |
parent | 9143e3925cd95d30af72745f25e185f65a686d32 (diff) |
More robust status notifications
Diffstat (limited to 'editors/code/src/lsp_ext.ts')
-rw-r--r-- | editors/code/src/lsp_ext.ts | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/editors/code/src/lsp_ext.ts b/editors/code/src/lsp_ext.ts index 00e128b8c..2e1744f1b 100644 --- a/editors/code/src/lsp_ext.ts +++ b/editors/code/src/lsp_ext.ts | |||
@@ -10,11 +10,12 @@ export interface AnalyzerStatusParams { | |||
10 | export const analyzerStatus = new lc.RequestType<AnalyzerStatusParams, string, void>("rust-analyzer/analyzerStatus"); | 10 | export const analyzerStatus = new lc.RequestType<AnalyzerStatusParams, string, void>("rust-analyzer/analyzerStatus"); |
11 | export const memoryUsage = new lc.RequestType0<string, void>("rust-analyzer/memoryUsage"); | 11 | export const memoryUsage = new lc.RequestType0<string, void>("rust-analyzer/memoryUsage"); |
12 | 12 | ||
13 | export type Status = "loading" | "ready" | "readyPartial" | "invalid" | "needsReload"; | 13 | export interface ServerStatusParams { |
14 | export interface StatusParams { | 14 | health: "ok" | "warning" | "error" |
15 | status: Status; | 15 | quiescent: boolean |
16 | message?: string | ||
16 | } | 17 | } |
17 | export const status = new lc.NotificationType<StatusParams>("rust-analyzer/status"); | 18 | export const serverStatus = new lc.NotificationType<ServerStatusParams>("experimental/serverStatus"); |
18 | 19 | ||
19 | export const reloadWorkspace = new lc.RequestType0<null, void>("rust-analyzer/reloadWorkspace"); | 20 | export const reloadWorkspace = new lc.RequestType0<null, void>("rust-analyzer/reloadWorkspace"); |
20 | 21 | ||