File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -714,6 +714,15 @@ export class RoslynLanguageServer {
714714 throw new Error ( `Invalid log level ${ logLevel } ` ) ;
715715 }
716716 }
717+
718+ public async getBuildOnlyDiagnosticIds ( token : vscode . CancellationToken ) : Promise < string [ ] > {
719+ const response = await _languageServer . sendRequest0 ( RoslynProtocol . BuildOnlyDiagnosticIdsRequest . type , token ) ;
720+ if ( response ) {
721+ return response . ids ;
722+ }
723+
724+ throw new Error ( 'Unable to retrieve build-only diagnostic ids for current solution.' ) ;
725+ }
717726}
718727
719728/**
Original file line number Diff line number Diff line change @@ -131,6 +131,10 @@ export interface ShowToastNotificationParams {
131131 commands : Command [ ] ;
132132}
133133
134+ export interface BuildOnlyDiagnosticIdsResult {
135+ ids : string [ ] ;
136+ }
137+
134138export namespace WorkspaceDebugConfigurationRequest {
135139 export const method = 'workspace/debugConfiguration' ;
136140 export const messageDirection : lsp . MessageDirection = lsp . MessageDirection . clientToServer ;
@@ -192,3 +196,9 @@ export namespace OpenProjectNotification {
192196 export const messageDirection : lsp . MessageDirection = lsp . MessageDirection . clientToServer ;
193197 export const type = new lsp . NotificationType < OpenProjectParams > ( method ) ;
194198}
199+
200+ export namespace BuildOnlyDiagnosticIdsRequest {
201+ export const method = 'workspace/buildOnlyDiagnosticIds' ;
202+ export const messageDirection : lsp . MessageDirection = lsp . MessageDirection . clientToServer ;
203+ export const type = new lsp . RequestType0 < BuildOnlyDiagnosticIdsResult , void > ( method ) ;
204+ }
You can’t perform that action at this time.
0 commit comments