MCPcopy Create free account
hub / github.com/Zoo-Code-Org/Zoo-Code / replace

Method replace

packages/vscode-shim/src/classes/TextEdit.ts:183–189  ·  view source on GitHub ↗

* Add a replace edit * * @param uri - The document URI * @param range - The range to replace * @param newText - The new text

(uri: { toString(): string }, range: IRange, newText: string)

Source from the content-addressed store, hash-verified

181 * @param newText - The new text
182 */
183 replace(uri: { toString(): string }, range: IRange, newText: string): void {
184 const key = uri.toString()
185 if (!this._edits.has(key)) {
186 this._edits.set(key, [])
187 }
188 this._edits.get(key)!.push(TextEdit.replace(range, newText))
189 }
190
191 /**
192 * Get the number of documents with edits

Callers 2

updateMethod · 0.95
revertChangesMethod · 0.95

Calls 5

toStringMethod · 0.65
hasMethod · 0.65
setMethod · 0.65
getMethod · 0.65
replaceMethod · 0.65

Tested by

no test coverage detected