@softvision/webpdf-wsclient-typescript
Version:
A simplified and optimized API client library for the webPDF server
88 lines • 4.13 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.MetadataBorderStyle = void 0;
class MetadataBorderStyle {
constructor(data) {
let dashPatternDefault = "";
this.dashPattern = typeof (data === null || data === void 0 ? void 0 : data.dashPattern) !== "undefined" ? data === null || data === void 0 ? void 0 : data.dashPattern : dashPatternDefault;
let dashPhaseDefault = 0;
this.dashPhase = typeof (data === null || data === void 0 ? void 0 : data.dashPhase) !== "undefined" ? data === null || data === void 0 ? void 0 : data.dashPhase : dashPhaseDefault;
let effectIntensityDefault = 0;
this.effectIntensity = typeof (data === null || data === void 0 ? void 0 : data.effectIntensity) !== "undefined" ? data === null || data === void 0 ? void 0 : data.effectIntensity : effectIntensityDefault;
let effectStyleDefault = "";
this.effectStyle = typeof (data === null || data === void 0 ? void 0 : data.effectStyle) !== "undefined" ? data === null || data === void 0 ? void 0 : data.effectStyle : effectStyleDefault;
let interiorColorDefault = "#4800FF";
this.interiorColor = typeof (data === null || data === void 0 ? void 0 : data.interiorColor) !== "undefined" ? data === null || data === void 0 ? void 0 : data.interiorColor : interiorColorDefault;
let styleDefault = "S";
this.style = typeof (data === null || data === void 0 ? void 0 : data.style) !== "undefined" ? data === null || data === void 0 ? void 0 : data.style : styleDefault;
let widthDefault = 1;
this.width = typeof (data === null || data === void 0 ? void 0 : data.width) !== "undefined" ? data === null || data === void 0 ? void 0 : data.width : widthDefault;
}
static getDashPatternDefault() {
return "";
}
static getDashPatternDescription() {
return "The dash pattern (array) of a dashed border. The dash array contains the unit lengths of alternating dashes and gaps, that shall be cycled through along the length of the border.";
}
static getDashPhaseDefault() {
return 0;
}
static getDashPhaseDescription() {
return "The phase of the dash pattern.";
}
static getEffectIntensityDefault() {
return 0;
}
static getEffectIntensityDescription() {
return "The intensity of a possibly set cloud effect, in a range from 0 to 2.";
}
static getEffectStyleDefault() {
return "";
}
static getEffectStyleDescription() {
return "The border effect to apply to the border shape.\n\n* S = Apply no border effects.\n* C = Apply a cloud pattern to the border shape.";
}
static getInteriorColorDefault() {
return "#4800FF";
}
static getInteriorColorDescription() {
return "The interior (fill) color for the shape.";
}
static getStyleDefault() {
return "S";
}
static getStyleDescription() {
return "The style of the shapes border.\n\n* S = Solid\n* D = Dashed\n* B = Beveled\n* I = Inset\n* U = Underline\n\n**Important:** Further custom styles may be contained and shall default to a solid border if unknown.";
}
static getWidthDefault() {
return 1;
}
static getWidthDescription() {
return "The border width\/line thickness in points.";
}
static getWidthMin() {
return 0;
}
static fromJson(data) {
if (data === undefined || data === null) {
return data;
}
return new MetadataBorderStyle(data);
}
toJson() {
return {
'dashPattern': this.dashPattern,
'dashPhase': this.dashPhase,
'effectIntensity': this.effectIntensity,
'effectStyle': this.effectStyle,
'interiorColor': this.interiorColor,
'style': this.style,
'width': this.width,
};
}
clone() {
return MetadataBorderStyle.fromJson(this.toJson());
}
}
exports.MetadataBorderStyle = MetadataBorderStyle;
//# sourceMappingURL=MetadataBorderStyle.js.map