@softvision/webpdf-wsclient-typescript
Version:
A simplified and optimized API client library for the webPDF server
58 lines • 1.97 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Margin = void 0;
class Margin {
constructor(data) {
let bottomDefault = 0;
this.bottom = typeof (data === null || data === void 0 ? void 0 : data.bottom) !== "undefined" ? data === null || data === void 0 ? void 0 : data.bottom : bottomDefault;
let leftDefault = 0;
this.left = typeof (data === null || data === void 0 ? void 0 : data.left) !== "undefined" ? data === null || data === void 0 ? void 0 : data.left : leftDefault;
let rightDefault = 0;
this.right = typeof (data === null || data === void 0 ? void 0 : data.right) !== "undefined" ? data === null || data === void 0 ? void 0 : data.right : rightDefault;
let topDefault = 0;
this.top = typeof (data === null || data === void 0 ? void 0 : data.top) !== "undefined" ? data === null || data === void 0 ? void 0 : data.top : topDefault;
}
static getBottomDefault() {
return 0;
}
static getBottomDescription() {
return "The bottom margin in points.";
}
static getLeftDefault() {
return 0;
}
static getLeftDescription() {
return "The left margin in points.";
}
static getRightDefault() {
return 0;
}
static getRightDescription() {
return "The right margin in points.";
}
static getTopDefault() {
return 0;
}
static getTopDescription() {
return "The top margin in points.";
}
static fromJson(data) {
if (data === undefined || data === null) {
return data;
}
return new Margin(data);
}
toJson() {
return {
'bottom': this.bottom,
'left': this.left,
'right': this.right,
'top': this.top,
};
}
clone() {
return Margin.fromJson(this.toJson());
}
}
exports.Margin = Margin;
//# sourceMappingURL=Margin.js.map