UNPKG

ravendb

Version:
35 lines 1.03 kB
import { throwError } from "../../../Exceptions/index.js"; import { RavenCommand } from "../../../Http/RavenCommand.js"; export class HiloReturnCommand extends RavenCommand { get isReadRequest() { return false; } _tag; _last; _end; constructor(tag, last, end) { super(); if (last < 0) { throwError("InvalidArgumentException", "last is < 0"); } if (end < 0) { throwError("InvalidArgumentException", "end is < 0"); } if (!tag) { throwError("InvalidArgumentException", "tag cannot be null"); } this._tag = tag; this._last = last; this._end = end; this._responseType = "Empty"; } createRequest(node) { const uri = `${node.url}/databases/${node.database}/hilo/return?` + `tag=${this._tag}&end=${this._end}&last=${this._last}`; return { method: "PUT", uri }; } } //# sourceMappingURL=HiloReturnCommand.js.map