import { TextDocument } from "https://deno.land/x/vscode_languageserver_textdocument@v0.1.0/mod.ts";
Functions
Creates a new text document. | |
Updates a TextDocument by modifing its content. |
import { type TextDocument } from "https://deno.land/x/vscode_languageserver_textdocument@v0.1.0/mod.ts";
A simple text document. Not to be implemented. The document keeps the content as string.
Properties
readonly
uri: DocumentUriThe associated URI for this document. Most documents have the file-scheme, indicating that they represent files on disk. However, some documents may have other schemes indicating that they are not available on disk.
Methods
getText(range?: Range): string
Get the text of this document. A substring can be retrieved by providing a range.
offsetAt(position: Position): number
Converts the position to a zero-based offset. Invalid positions are adjusted as described in Position.line and Position.character.