@softvision/webpdf-wsclient-typescript
Version:
A simplified and optimized API client library for the webPDF server
55 lines • 2.13 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.AnnotationSelection = void 0;
class AnnotationSelection {
constructor(data) {
let indexDefault = 0;
this.index = typeof (data === null || data === void 0 ? void 0 : data.index) !== "undefined" ? data === null || data === void 0 ? void 0 : data.index : indexDefault;
let nameDefault = "";
this.name = typeof (data === null || data === void 0 ? void 0 : data.name) !== "undefined" ? data === null || data === void 0 ? void 0 : data.name : nameDefault;
let pageDefault = 1;
this.page = typeof (data === null || data === void 0 ? void 0 : data.page) !== "undefined" ? data === null || data === void 0 ? void 0 : data.page : pageDefault;
}
static getIndexDefault() {
return 0;
}
static getIndexDescription() {
return "The index for the annotation in the page's annotation directory. This value is an alternative to the annotation name and does not have to be set if an annotation name is specified.";
}
static getIndexMin() {
return 0;
}
static getNameDefault() {
return "";
}
static getNameDescription() {
return "The name of the annotation in the page's annotation directory. This value is an alternative to the annotation index and does not have to be set if an annotation index is specified.";
}
static getPageDefault() {
return 1;
}
static getPageDescription() {
return "The page number of the page where the annotation is found.";
}
static getPageMin() {
return 1;
}
static fromJson(data) {
if (data === undefined || data === null) {
return data;
}
return new AnnotationSelection(data);
}
toJson() {
return {
'index': this.index,
'name': this.name,
'page': this.page,
};
}
clone() {
return AnnotationSelection.fromJson(this.toJson());
}
}
exports.AnnotationSelection = AnnotationSelection;
//# sourceMappingURL=AnnotationSelection.js.map