Table of Contents

Interface IServerCommandContext

Namespace
RDCore.SDK.Server.Commands
Assembly
RDCore.SDK.dll

What a server command can ask of the client while it runs.

public interface IServerCommandContext

Methods

AskAsync(string, IReadOnlyList<string>, CancellationToken)

Asks the client's user to choose (LSP 3.17 window/showMessageRequest): whether to replace a file, which of several projects.

Task<string?> AskAsync(string message, IReadOnlyList<string> choices, CancellationToken token)

Parameters

message string

The question, in the language of the user interface.

choices IReadOnlyList<string>

What the user can choose, as the buttons say it.

token CancellationToken

A token that cancels the question.

Returns

Task<string>

The choice; null when the user chose none - closed the question, or has a client that asks no questions.