TypeQLiteCompletionProvider
Defined in: libs/language/src/typeqlite-completion.ts:23
Completion for TypeQLite.
Langium already completes keywords, and cross-references from their scope: owns, sub and
plays in a define, which since ADR-008 D3 means the whole workspace. What it cannot complete is
a label that is a plain ID (isa |, has |, a role player), because there is no scope to ask.
Those positions are listed in LABEL_POSITIONS, and offer the workspace’s definitions of the kind
each one expects (ADR-008 D5).
Extends
Section titled “Extends”Member summary
Section titled “Member summary”Constructors
| Name | Description |
|---|---|
| new TypeQLiteCompletionProvider() | Created with the language’s services by TypeQLiteModule. |
Properties
| Name | Description |
|---|---|
| completionOptions? | Contains the completion options for this completion provider. |
Methods
| Name | Description |
|---|---|
| getCompletion() | Handle a completion request. |
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new TypeQLiteCompletionProvider(
services):TypeQLiteCompletionProvider
Defined in: libs/language/src/typeqlite-completion.ts:31
Created with the language’s services by TypeQLiteModule.
Parameters
Section titled “Parameters”services
Section titled “services”LangiumGeneratedCoreServices & LangiumDefaultCoreServices & LangiumLSPServices & object
Langium’s services, with the label resolver.
Returns
Section titled “Returns”TypeQLiteCompletionProvider
Overrides
Section titled “Overrides”DefaultCompletionProvider.constructor
Properties
Section titled “Properties”completionOptions?
Section titled “completionOptions?”
readonlyoptionalcompletionOptions?:CompletionProviderOptions
Defined in: node_modules/langium/lib/lsp/completion/completion-provider.d.ts:117
Contains the completion options for this completion provider.
If multiple languages return different options, they are merged before being sent to the language client.
Inherited from
Section titled “Inherited from”DefaultCompletionProvider.completionOptions
Methods
Section titled “Methods”getCompletion()
Section titled “getCompletion()”getCompletion(
document,params,_cancelToken?):Promise<CompletionList|undefined>
Defined in: node_modules/langium/lib/lsp/completion/completion-provider.d.ts:120
Handle a completion request.
Parameters
Section titled “Parameters”document
Section titled “document”the document for which the completion request was triggered
params
Section titled “params”CompletionParams
the completion parameters
_cancelToken?
Section titled “_cancelToken?”CancellationToken
Returns
Section titled “Returns”Promise<CompletionList | undefined>
Throws
Section titled “Throws”OperationCancelled if cancellation is detected during execution
Throws
Section titled “Throws”ResponseError if an error is detected that should be sent as response to the client
Inherited from
Section titled “Inherited from”DefaultCompletionProvider.getCompletion
TypeDBLite is an independent open-source project, built on TypeDB with thanks. It is not affiliated with, sponsored by, or endorsed by TypeDB Ltd. Released under the MPL-2.0 license.