Document.this

Creates a new document at the given document URI, with version 0 and no text and guessed language ID. See getLanguageId

  1. this(DocumentUri uri)
    struct Document
  2. this(TextDocumentItem doc)

Examples

auto doc = Document("file:///home/projects/app.d");
assert(doc.uri == "file:///home/projects/app.d");
assert(doc.languageId == "d");
assert(doc.version_ == 0);
assert(!doc.rawText.length);

Meta