clang-tools 10.0.0

Public Attributes | Static Public Attributes | List of all members
clang::clangd::ExecuteCommandParams Struct Reference

Exact commands are not specified in the protocol so we define the ones supported by Clangd here. More...

`#include <Protocol.h>`

Inheritance diagram for clang::clangd::ExecuteCommandParams:
[legend]
Collaboration diagram for clang::clangd::ExecuteCommandParams:
[legend]

## Public Attributes
std::string | command
| The command identifier, e.g. CLANGD_APPLY_FIX_COMMAND. More...
llvm::Optional< WorkspaceEdit > | workspaceEdit
llvm::Optional< TweakArgs > | tweakArgs

## Static Public Attributes
static const llvm::StringLiteral | CLANGD_APPLY_FIX_COMMAND
static const llvm::StringLiteral | CLANGD_APPLY_TWEAK

## Detailed Description

Exact commands are not specified in the protocol so we define the ones supported by Clangd here.

The protocol specifies the command arguments to be "any[]" but to make this safer and more manageable, each command we handle maps to a certain llvm::Optional of some struct to contain its arguments. Different commands could reuse the same llvm::Optional as arguments but a command that needs different arguments would simply add a new llvm::Optional and not use any other ones. In practice this means only one argument type will be parsed and set.

Definition at line 746 of file Protocol.h.

## Member Data Documentation

## ◆ CLANGD_APPLY_FIX_COMMAND

const llvm::StringLiteral clang::clangd::ExecuteCommandParams::CLANGD_APPLY_FIX_COMMAND
| static

Initial value:
=
"clangd.applyFix"

Definition at line 748 of file Protocol.h.

## ◆ CLANGD_APPLY_TWEAK

const llvm::StringLiteral clang::clangd::ExecuteCommandParams::CLANGD_APPLY_TWEAK
| static

Initial value:
=
"clangd.applyTweak"

Definition at line 750 of file Protocol.h.

## ◆ command

std::string clang::clangd::ExecuteCommandParams::command

The command identifier, e.g. CLANGD_APPLY_FIX_COMMAND.

Definition at line 753 of file Protocol.h.

## ◆ tweakArgs

llvm::Optional<TweakArgs> clang::clangd::ExecuteCommandParams::tweakArgs

Definition at line 757 of file Protocol.h.

## ◆ workspaceEdit

llvm::Optional<WorkspaceEdit> clang::clangd::ExecuteCommandParams::workspaceEdit

Definition at line 756 of file Protocol.h.

The documentation for this struct was generated from the following files:

- Protocol.h
- Protocol.cpp