DocumentSemanticTokensProvider
ts
interface DocumentSemanticTokensProvider {
onDidChange?: IEvent<void>;
getLegend(): SemanticTokensLegend;
provideDocumentSemanticTokens(model, lastResultId, token): ProviderResult<SemanticTokens | SemanticTokensEdits>;
releaseDocumentSemanticTokens(resultId): void;
}
onDidChange
- 类型:IEvent
<void>
getLegend
- 语法:
getLegend(): SemanticTokensLegend
- 返回值:SemanticTokensLegend
provideDocumentSemanticTokens
- 语法:
provideDocumentSemanticTokens(model, lastResultId, token): ProviderResult<SemanticTokens | SemanticTokensEdits>
- 参数:
- model:ITextModel
- lastResultId:
string
- token:CancellationToken
- 返回值:ProviderResult
<
SemanticTokens|
SemanticTokensEdits>
releaseDocumentSemanticTokens
- 语法:
releaseDocumentSemanticTokens(resultId): void
- 参数:
resultId
:string