@softvision/webpdf-wsclient-typescript
Version:
A simplified and optimized API client library for the webPDF server
67 lines • 2.63 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.HistoryEntry = void 0;
class HistoryEntry {
constructor(data) {
let activeDefault = false;
this.active = typeof (data === null || data === void 0 ? void 0 : data.active) !== "undefined" ? data === null || data === void 0 ? void 0 : data.active : activeDefault;
let dateTimeDefault = "";
this.dateTime = typeof (data === null || data === void 0 ? void 0 : data.dateTime) !== "undefined" ? data === null || data === void 0 ? void 0 : data.dateTime : dateTimeDefault;
let fileNameDefault = "";
this.fileName = typeof (data === null || data === void 0 ? void 0 : data.fileName) !== "undefined" ? data === null || data === void 0 ? void 0 : data.fileName : fileNameDefault;
let idDefault = 0;
this.id = typeof data.id !== "undefined" ? data.id : idDefault;
let operationDefault = "";
this.operation = typeof (data === null || data === void 0 ? void 0 : data.operation) !== "undefined" ? data === null || data === void 0 ? void 0 : data.operation : operationDefault;
}
static getActiveDefault() {
return false;
}
static getActiveDescription() {
return "When this is set to **true** the entry is still active and may be reverted to.";
}
static getDateTimeDefault() {
return "";
}
static getDateTimeDescription() {
return "The creation time of the entry.";
}
static getFileNameDefault() {
return "";
}
static getFileNameDescription() {
return "The file name used for this entry.";
}
static getIdDefault() {
return 0;
}
static getIdDescription() {
return "The unique history id in the server\u00B4s **document storage**.";
}
static getOperationDefault() {
return "";
}
static getOperationDescription() {
return "The name of the operation executed for the entry. (The name of the webservice - optionally followed by ':' and the name of the executed operation.)";
}
static fromJson(data) {
if (data === undefined || data === null) {
return data;
}
return new HistoryEntry(data);
}
toJson() {
return {
'active': this.active,
'dateTime': this.dateTime,
'fileName': this.fileName,
'id': this.id,
'operation': this.operation,
};
}
clone() {
return HistoryEntry.fromJson(this.toJson());
}
}
exports.HistoryEntry = HistoryEntry;
//# sourceMappingURL=HistoryEntry.js.map