@softvision/webpdf-wsclient-typescript
Version:
A simplified and optimized API client library for the webPDF server
55 lines • 1.97 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.OcrPage = void 0;
class OcrPage {
constructor(data) {
let heightDefault = 297;
this.height = typeof (data === null || data === void 0 ? void 0 : data.height) !== "undefined" ? data === null || data === void 0 ? void 0 : data.height : heightDefault;
let metricsDefault = "mm";
this.metrics = typeof (data === null || data === void 0 ? void 0 : data.metrics) !== "undefined" ? data === null || data === void 0 ? void 0 : data.metrics : metricsDefault;
let widthDefault = 210;
this.width = typeof (data === null || data === void 0 ? void 0 : data.width) !== "undefined" ? data === null || data === void 0 ? void 0 : data.width : widthDefault;
}
static getHeightDefault() {
return 297;
}
static getHeightDescription() {
return "Height of the page in the PDF document.";
}
static getHeightMin() {
return 0;
}
static getMetricsDefault() {
return "mm";
}
static getMetricsDescription() {
return "Unit for the X-axis\/Y-axis position and signature field height and width arguments:\n\n* pt = Points(1\/72 inch)\n* pc = Picas(12 points)\n* px = Pixels(1\/96 inch)\n* mm = Millimeters\n* in = Inches";
}
static getWidthDefault() {
return 210;
}
static getWidthDescription() {
return "Width of the page in the PDF document.";
}
static getWidthMin() {
return 0;
}
static fromJson(data) {
if (data === undefined || data === null) {
return data;
}
return new OcrPage(data);
}
toJson() {
return {
'height': this.height,
'metrics': this.metrics,
'width': this.width,
};
}
clone() {
return OcrPage.fromJson(this.toJson());
}
}
exports.OcrPage = OcrPage;
//# sourceMappingURL=OcrPage.js.map