UNPKG

ravendb

Version:
48 lines 1.26 kB
import { TimeSeriesOperation } from "../../Operations/TimeSeries/TimeSeriesOperation.js"; import { throwError } from "../../../Exceptions/index.js"; export class TimeSeriesCommandData { _id; _name; _timeSeries; constructor(documentId, name) { if (!documentId) { throwError("InvalidArgumentException", "DocumentId cannot be null"); } if (!name) { throwError("InvalidArgumentException", "Name cannot be null"); } this._id = documentId; this._name = name; this._timeSeries = new TimeSeriesOperation(); this._timeSeries.name = name; } get id() { return this._id; } set id(value) { this._id = value; } get name() { return this._name; } set name(value) { this._name = value; } get changeVector() { return null; } get timeSeries() { return this._timeSeries; } serialize(conventions) { return { Id: this._id, TimeSeries: this._timeSeries.serialize(conventions), Type: "TimeSeries" }; } onBeforeSaveChanges(session) { // empty by design } } //# sourceMappingURL=TimeSeriesCommandData.js.map