pub enum InsertTextFormat {
PlainText,
Snippet,
}Expand description
Defines whether the insert text in a completion item should be interpreted as plain text or a snippet.
Variants§
PlainText
The primary text to be inserted is treated as a plain string.
Snippet
The primary text to be inserted is treated as a snippet.
A snippet can define tab stops and placeholders with $1, $2
and ${3:foo}. $0 defines the final tab stop, it defaults to
the end of the snippet. Placeholders with equal identifiers are linked,
that is typing in one will update others too.
See also: https://microsoft.github.io/language-server-protocol/specifications/specification-current/#snippet_syntax
Trait Implementations§
Source§impl Clone for InsertTextFormat
impl Clone for InsertTextFormat
Source§fn clone(&self) -> InsertTextFormat
fn clone(&self) -> InsertTextFormat
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for InsertTextFormat
impl Debug for InsertTextFormat
Source§impl<'de> Deserialize<'de> for InsertTextFormat
impl<'de> Deserialize<'de> for InsertTextFormat
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<InsertTextFormat> for u32
impl From<InsertTextFormat> for u32
Source§fn from(e: InsertTextFormat) -> Self
fn from(e: InsertTextFormat) -> Self
Converts to this type from the input type.
Source§impl Hash for InsertTextFormat
impl Hash for InsertTextFormat
Source§impl PartialEq for InsertTextFormat
impl PartialEq for InsertTextFormat
Source§fn eq(&self, other: &InsertTextFormat) -> bool
fn eq(&self, other: &InsertTextFormat) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for InsertTextFormat
impl Serialize for InsertTextFormat
Source§impl TryFrom<u32> for InsertTextFormat
impl TryFrom<u32> for InsertTextFormat
impl Copy for InsertTextFormat
impl Eq for InsertTextFormat
impl StructuralPartialEq for InsertTextFormat
Auto Trait Implementations§
impl Freeze for InsertTextFormat
impl RefUnwindSafe for InsertTextFormat
impl Send for InsertTextFormat
impl Sync for InsertTextFormat
impl Unpin for InsertTextFormat
impl UnsafeUnpin for InsertTextFormat
impl UnwindSafe for InsertTextFormat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more