UNPKG

@softvision/webpdf-wsclient-typescript

Version:

A simplified and optimized API client library for the webPDF server

53 lines 2.1 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.HtmlTranscribe = void 0; const index_1 = require("./../index"); class HtmlTranscribe { constructor(data) { let dpiDefault = 72; this.dpi = typeof (data === null || data === void 0 ? void 0 : data.dpi) !== "undefined" ? data === null || data === void 0 ? void 0 : data.dpi : dpiDefault; let pagesDefault = "1"; this.pages = typeof (data === null || data === void 0 ? void 0 : data.pages) !== "undefined" ? data === null || data === void 0 ? void 0 : data.pages : pagesDefault; this.svgFormat = index_1.SvgFormat.fromJson(data === null || data === void 0 ? void 0 : data.svgFormat); } static getDpiDefault() { return 72; } static getDpiDescription() { return "This parameter sets the DPI resolution of the document. The larger the value, the larger the X\/Y resolution of the document's pages and generated raster graphics. Also, as the DPI resolution increases, so does the byte size of the document."; } static getDpiMin() { return 0; } static getDpiMax() { return 9600; } static getPagesDefault() { return "1"; } static getPagesDescription() { return "Specifies which page(s) to convert. The page number can be either a single page, a range of pages or a list (separated by commas) (e.g. \"1,5-6,9\"). The specification of all pages is done with \"\\*\"."; } static getSvgFormatDescription() { return ""; } static fromJson(data) { if (data === undefined || data === null) { return data; } return new HtmlTranscribe(data); } toJson() { var _a; return { 'dpi': this.dpi, 'pages': this.pages, 'svgFormat': (_a = this.svgFormat) === null || _a === void 0 ? void 0 : _a.toJson(), }; } clone() { return HtmlTranscribe.fromJson(this.toJson()); } } exports.HtmlTranscribe = HtmlTranscribe; //# sourceMappingURL=HtmlTranscribe.js.map