UNPKG

igniteui-angular-gauges

Version:

Ignite UI Angular gauge components.

412 lines (411 loc) 12.8 kB
/* THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE: https://www.infragistics.com/legal/license/igultimate-la https://www.infragistics.com/legal/license/igultimate-eula GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company. */ import { __extends, __values } from "tslib"; import { Base, fromEnum, markType } from "igniteui-angular-core"; import { StringBuilder } from "igniteui-angular-core"; /** * @hidden */ var LinearGraphVisualData = /** @class */ /*@__PURE__*/ (function (_super) { __extends(LinearGraphVisualData, _super); function LinearGraphVisualData() { var _this = _super !== null && _super.apply(this, arguments) || this; _this._scalePath = null; _this._backingPath = null; _this._underlayPath = null; _this._overlayPath = null; _this._scale = null; _this._scaleLabels = null; _this._scaleTickmarks = null; _this._ranges = null; _this._toolTip = null; _this._name = null; _this._viewport = null; return _this; } Object.defineProperty(LinearGraphVisualData.prototype, "scalePath", { get: function () { return this._scalePath; }, set: function (a) { this._scalePath = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "backingPath", { get: function () { return this._backingPath; }, set: function (a) { this._backingPath = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "underlayPath", { get: function () { return this._underlayPath; }, set: function (a) { this._underlayPath = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "overlayPath", { get: function () { return this._overlayPath; }, set: function (a) { this._overlayPath = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "scale", { get: function () { return this._scale; }, set: function (a) { this._scale = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "scaleLabels", { get: function () { return this._scaleLabels; }, set: function (a) { this._scaleLabels = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "scaleTickmarks", { get: function () { return this._scaleTickmarks; }, set: function (a) { this._scaleTickmarks = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "ranges", { get: function () { return this._ranges; }, set: function (a) { this._ranges = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "toolTip", { get: function () { return this._toolTip; }, set: function (a) { this._toolTip = a; }, enumerable: false, configurable: true }); Object.defineProperty(LinearGraphVisualData.prototype, "name", { get: function () { return this._name; }, set: function (a) { this._name = a; }, enumerable: false, configurable: true }); LinearGraphVisualData.prototype.scaleByViewport = function () { var e_1, _a, e_2, _b, e_3, _c; if (this.scalePath != null) { this.scalePath.scaleByViewport(this.viewport); } if (this.backingPath != null) { this.backingPath.scaleByViewport(this.viewport); } if (this.underlayPath != null) { this.underlayPath.scaleByViewport(this.viewport); } if (this.overlayPath != null) { this.overlayPath.scaleByViewport(this.viewport); } if (this.scaleLabels != null) { try { for (var _d = __values(fromEnum(this.scaleLabels)), _e = _d.next(); !_e.done; _e = _d.next()) { var a = _e.value; a.scaleByViewport(this.viewport); } } catch (e_1_1) { e_1 = { error: e_1_1 }; } finally { try { if (_e && !_e.done && (_a = _d.return)) _a.call(_d); } finally { if (e_1) throw e_1.error; } } } if (this.scaleTickmarks != null) { try { for (var _f = __values(fromEnum(this.scaleTickmarks)), _g = _f.next(); !_g.done; _g = _f.next()) { var b = _g.value; if (b.tickPath != null) { b.tickPath.scaleByViewport(this.viewport); } } } catch (e_2_1) { e_2 = { error: e_2_1 }; } finally { try { if (_g && !_g.done && (_b = _f.return)) _b.call(_f); } finally { if (e_2) throw e_2.error; } } } if (this.ranges != null) { try { for (var _h = __values(fromEnum(this.ranges)), _j = _h.next(); !_j.done; _j = _h.next()) { var c = _j.value; if (c.rangePath != null) { c.rangePath.scaleByViewport(this.viewport); } } } catch (e_3_1) { e_3 = { error: e_3_1 }; } finally { try { if (_j && !_j.done && (_c = _h.return)) _c.call(_h); } finally { if (e_3) throw e_3.error; } } } }; LinearGraphVisualData.prototype.serialize = function () { var e_4, _a, e_5, _b, e_6, _c; var a = new StringBuilder(0); var b = true; a.u("{"); if (this.scalePath != null) { if (b) { b = false; } else { a.l(", "); } a.l("scalePath: "); a.u(this.scalePath.serialize()); } if (this.backingPath != null) { if (b) { b = false; } else { a.l(", "); } a.l("backingPath: "); a.u(this.backingPath.serialize()); } if (this.underlayPath != null) { if (b) { b = false; } else { a.l(", "); } a.l("underlayPath: "); a.u(this.underlayPath.serialize()); } if (this.overlayPath != null) { if (b) { b = false; } else { a.l(", "); } a.l("overlayPath: "); a.u(this.overlayPath.serialize()); } if (this.scaleLabels != null) { if (b) { b = false; } else { a.l(", "); } var c = true; a.l("scaleLabels: ["); try { for (var _d = __values(fromEnum(this.scaleLabels)), _e = _d.next(); !_e.done; _e = _d.next()) { var d = _e.value; if (c) { c = false; } else { a.l(", "); } a.u(d.serialize()); } } catch (e_4_1) { e_4 = { error: e_4_1 }; } finally { try { if (_e && !_e.done && (_a = _d.return)) _a.call(_d); } finally { if (e_4) throw e_4.error; } } a.u("]"); } if (this.scaleTickmarks != null) { if (b) { b = false; } else { a.l(", "); } var e = true; a.l("scaleTickmarks: ["); try { for (var _f = __values(fromEnum(this.scaleTickmarks)), _g = _f.next(); !_g.done; _g = _f.next()) { var f = _g.value; if (e) { e = false; } else { a.l(", "); } a.u(f.serialize()); } } catch (e_5_1) { e_5 = { error: e_5_1 }; } finally { try { if (_g && !_g.done && (_b = _f.return)) _b.call(_f); } finally { if (e_5) throw e_5.error; } } a.u("]"); } if (this.ranges != null) { if (b) { b = false; } else { a.l(", "); } var g = true; a.l("ranges: ["); try { for (var _h = __values(fromEnum(this.ranges)), _j = _h.next(); !_j.done; _j = _h.next()) { var h = _j.value; if (g) { g = false; } else { a.l(", "); } a.u(h.serialize()); } } catch (e_6_1) { e_6 = { error: e_6_1 }; } finally { try { if (_j && !_j.done && (_c = _h.return)) _c.call(_h); } finally { if (e_6) throw e_6.error; } } a.u("]"); } if (this.name != null) { if (b) { b = false; } else { a.l(", "); } a.l("name: '"); a.l(this.name); a.u("'"); } if (this.toolTip != null) { if (b) { b = false; } else { a.l(", "); } a.l("toolTip: "); a.l(this.toolTip.serialize()); } if (b) { b = false; } else { a.l(", "); } a.l("viewport: {"); a.l("left: " + this.viewport.left + ", top: " + this.viewport.top + ", width: " + this.viewport.width + ", height: " + this.viewport.height); a.u("}"); a.l("}"); return a.toString(); }; Object.defineProperty(LinearGraphVisualData.prototype, "viewport", { get: function () { return this._viewport; }, set: function (a) { this._viewport = a; }, enumerable: false, configurable: true }); LinearGraphVisualData.$t = markType(LinearGraphVisualData, 'LinearGraphVisualData'); return LinearGraphVisualData; }(Base)); export { LinearGraphVisualData };