Struct lsp::types::CodeAction[][src]

pub struct CodeAction {
    pub title: String,
    pub kind: Option<CodeActionKind>,
    pub diagnostics: Option<Vec<Diagnostic>>,
    pub edit: Option<WorkspaceEdit>,
    pub command: Option<Command>,
}

A code action represents a change that can be performed in code, e.g. to fix a problem or to refactor code.

A CodeAction must set either edit and/or a command. If both are supplied, the edit is applied first, then the command is executed.

Fields

A short, human-readable, title for this code action.

The kind of the code action.

Used to filter code actions.

The diagnostics that this code action resolves.

The workspace edit this code action performs.

A command this code action executes. If a code action provides a edit and a command, first the edit is executed and then the command.

Methods

impl CodeAction
[src]

Creates a new code action.

@param title The title of the code action. @param command The command to execute. @param kind The kind of the code action.

Creates a new code action.

@param title The title of the code action. @param command The command to execute. @param kind The kind of the code action.

Trait Implementations

impl Debug for CodeAction
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for CodeAction

impl Sync for CodeAction