class LSProtocol::CompletionItemDefaults
- LSProtocol::CompletionItemDefaults
- Reference
- Object
Overview
In many cases the items of an actual completion result share the same
value for properties like commitCharacters
or the range of a text
edit. A completion list can therefore define item defaults which will
be used if a completion item itself doesn't specify the value.
If a completion list specifies a default value and a completion item
also specifies a corresponding value, the rules for combining these are
defined by applyKinds
(if the client supports it), defaulting to
"replace".
Servers are only allowed to return default values if the client
signals support for this via the completionList.itemDefaults
capability.
@since 3.17.0
Included Modules
- JSON::Serializable
Defined in:
lsprotocol/types.crConstructors
- .new(pull : JSON::PullParser)
- .new(commit_characters : Array(String) | Nil = nil, data : LSPAny | Nil = nil, edit_range : EditRangeWithInsertReplace | Range | Nil = nil, insert_text_format : InsertTextFormat | Nil = nil, insert_text_mode : InsertTextMode | Nil = nil)
Instance Method Summary
- #commit_characters : Array(String) | Nil
-
#data : LSPAny | Nil
A default data value.
- #edit_range : EditRangeWithInsertReplace | Range | Nil
- #insert_text_format : InsertTextFormat | Nil
- #insert_text_mode : InsertTextMode | Nil
Constructor Detail
def self.new(commit_characters : Array(String) | Nil = nil, data : LSPAny | Nil = nil, edit_range : EditRangeWithInsertReplace | Range | Nil = nil, insert_text_format : InsertTextFormat | Nil = nil, insert_text_mode : InsertTextMode | Nil = nil)
#