| 1 |
#pragma once |
| 2 |
|
| 3 |
#include "LibLsp/lsp/lsDocumentUri.h" |
| 4 |
|
| 5 |
#include "LibLsp/JsonRpc/RequestInMessage.h" |
| 6 |
#include "LibLsp/JsonRpc/lsResponseMessage.h" |
| 7 |
|
| 8 |
/** |
| 9 |
* General parameters to unregister a capability. |
| 10 |
*/ |
| 11 |
|
| 12 |
struct Unregistration |
| 13 |
{ |
| 14 |
/** |
| 15 |
* The id used to unregister the request or notification. Usually an id |
| 16 |
* provided during the register request. |
| 17 |
*/ |
| 18 |
|
| 19 |
std::string id; |
| 20 |
|
| 21 |
/** |
| 22 |
* The method / capability to unregister for. |
| 23 |
*/ |
| 24 |
|
| 25 |
std::string method; |
| 26 |
|
| 27 |
MAKE_SWAP_METHOD(Unregistration, id, method); |
| 28 |
}; |
| 29 |
MAKE_REFLECT_STRUCT(Unregistration, id, method); |
| 30 |
/** |
| 31 |
* The client/unregisterCapability request is sent from the server to the client to unregister |
| 32 |
* a previously registered capability. |
| 33 |
*/ |
| 34 |
struct UnregistrationParams |
| 35 |
{ |
| 36 |
std::vector<Unregistration> unregisterations; |
| 37 |
MAKE_SWAP_METHOD(UnregistrationParams, unregisterations); |
| 38 |
}; |
| 39 |
|
| 40 |
MAKE_REFLECT_STRUCT(UnregistrationParams, unregisterations); |
| 41 |
|
| 42 |
DEFINE_REQUEST_RESPONSE_TYPE( |
| 43 |
Req_ClientUnregisterCapability, UnregistrationParams, JsonNull, "client/unregisterCapability" |
| 44 |
); |