Struct lsp::types::TextEdit[][src]

pub struct TextEdit {
    pub range: Range,
    pub new_text: String,
}

A text edit applicable to a text document.

Fields

The range of the text document to be manipulated. To insert text into a document create a range where start === end.

The string to be inserted. For delete operations use an empty string.

Methods

impl TextEdit
[src]

The TextEdit namespace provides helper function to create replace, insert and delete edits more easily.

Creates a replace text edit. @param range The range of text to be replaced. @param newText The new text.

Creates a insert text edit. @param position The position to insert the text at. @param newText The text to be inserted.

Creates a delete text edit. @param range The range of text to be deleted.

Trait Implementations

impl Debug for TextEdit
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for TextEdit

impl Sync for TextEdit