CompletionResultsParams class
completion.results params
{ "id": CompletionId "replacementOffset": int "replacementLength": int "results": List
Clients may not extend, implement or mix-in this class.
Constructors
-
CompletionResultsParams(String id, int replacementOffset, int replacementLength, List<
CompletionSuggestion> results, bool isLast, {String? libraryFile, List<IncludedSuggestionSet> ? includedSuggestionSets, List<ElementKind> ? includedElementKinds, List<IncludedSuggestionRelevanceTag> ? includedSuggestionRelevanceTags}) - CompletionResultsParams.fromJson(JsonDecoder jsonDecoder, String jsonPath, Object? json)
-
factory
- CompletionResultsParams.fromNotification(Notification notification)
-
factory
Properties
- hashCode → int
-
The hash code for this object.
no setteroverride
- id ↔ String
-
The id associated with the completion.
getter/setter pair
-
includedElementKinds
↔ List<
ElementKind> ? -
The client is expected to check this list against the ElementKind sent in
IncludedSuggestionSet to decide whether or not these symbols should
should be presented to the user.
getter/setter pair
-
includedSuggestionRelevanceTags
↔ List<
IncludedSuggestionRelevanceTag> ? -
The client is expected to check this list against the values of the field
relevanceTags of AvailableSuggestion to decide if the suggestion should
be given a different relevance than the IncludedSuggestionSet that
contains it. This might be used for example to give higher relevance to
suggestions of matching types.
getter/setter pair
-
includedSuggestionSets
↔ List<
IncludedSuggestionSet> ? -
References to AvailableSuggestionSet objects previously sent to the
client. The client can include applicable names from the referenced
library in code completion suggestions.
getter/setter pair
- isLast ↔ bool
-
True if this is that last set of results that will be returned for the
indicated completion.
getter/setter pair
- libraryFile ↔ String?
-
The library file that contains the file where completion was requested.
The client might use it for example together with the existingImports
notification to filter out available suggestions. If there were changes
to existing imports in the library, the corresponding existingImports
notification will be sent before the completion notification.
getter/setter pair
- replacementLength ↔ int
-
The length of the text to be replaced if the remainder of the identifier
containing the cursor is to be replaced when the suggestion is applied
(that is, the number of characters in the existing identifier).
getter/setter pair
- replacementOffset ↔ int
-
The offset of the start of the text to be replaced. This will be
different than the offset used to request the completion suggestions if
there was a portion of an identifier before the original offset. In
particular, the replacementOffset will be the offset of the beginning of
said identifier.
getter/setter pair
-
results
↔ List<
CompletionSuggestion> -
The completion suggestions being reported. The notification contains all
possible completions at the requested cursor position, even those that do
not match the characters the user has already typed. This allows the
client to respond to further keystrokes from the user without having to
make additional requests.
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, Object> - Returns a JSON presentation of the object.
-
toNotification(
) → Notification -
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override