/*
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 { PrimitiveVisualDataList } from "igniteui-angular-core";
import { PointerTooltipVisualDataList } from "./PointerTooltipVisualDataList";
import { MarkerVisualDataList } from "./MarkerVisualDataList";
import { CalloutVisualDataList } from "./CalloutVisualDataList";
import { StringBuilder } from "igniteui-angular-core";
/**
 * @hidden
 */
var SeriesVisualData = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(SeriesVisualData, _super);
    function SeriesVisualData() {
        var _this = _super.call(this) || this;
        _this._name = null;
        _this._type = null;
        _this._viewport = null;
        _this._opacity = 0;
        _this._shapes = null;
        _this._pointerTooltips = null;
        _this._markerShapes = null;
        _this._calloutShapes = null;
        _this._pixels = null;
        _this._pixelWidth = 0;
        _this._pixelHeight = 0;
        _this.shapes = new PrimitiveVisualDataList();
        _this.markerShapes = new MarkerVisualDataList();
        _this.pointerTooltips = new PointerTooltipVisualDataList();
        _this.calloutShapes = new CalloutVisualDataList();
        return _this;
    }
    Object.defineProperty(SeriesVisualData.prototype, "name", {
        get: function () {
            return this._name;
        },
        set: function (a) {
            this._name = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "type", {
        get: function () {
            return this._type;
        },
        set: function (a) {
            this._type = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "viewport", {
        get: function () {
            return this._viewport;
        },
        set: function (a) {
            this._viewport = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "opacity", {
        get: function () {
            return this._opacity;
        },
        set: function (a) {
            this._opacity = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "shapes", {
        get: function () {
            return this._shapes;
        },
        set: function (a) {
            this._shapes = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "pointerTooltips", {
        get: function () {
            return this._pointerTooltips;
        },
        set: function (a) {
            this._pointerTooltips = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "markerShapes", {
        get: function () {
            return this._markerShapes;
        },
        set: function (a) {
            this._markerShapes = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "calloutShapes", {
        get: function () {
            return this._calloutShapes;
        },
        set: function (a) {
            this._calloutShapes = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "pixels", {
        get: function () {
            return this._pixels;
        },
        set: function (a) {
            this._pixels = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "pixelWidth", {
        get: function () {
            return this._pixelWidth;
        },
        set: function (a) {
            this._pixelWidth = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(SeriesVisualData.prototype, "pixelHeight", {
        get: function () {
            return this._pixelHeight;
        },
        set: function (a) {
            this._pixelHeight = a;
        },
        enumerable: false,
        configurable: true
    });
    SeriesVisualData.prototype.m = function () {
        var e_1, _a, e_2, _b, e_3, _c, e_4, _d;
        try {
            for (var _e = __values(fromEnum(this.shapes)), _f = _e.next(); !_f.done; _f = _e.next()) {
                var a = _f.value;
                a.scaleByViewport(this.viewport);
            }
        }
        catch (e_1_1) {
            e_1 = { error: e_1_1 };
        }
        finally {
            try {
                if (_f && !_f.done && (_a = _e.return))
                    _a.call(_e);
            }
            finally {
                if (e_1)
                    throw e_1.error;
            }
        }
        try {
            for (var _g = __values(fromEnum(this.markerShapes)), _h = _g.next(); !_h.done; _h = _g.next()) {
                var b = _h.value;
                b.i(this.viewport);
            }
        }
        catch (e_2_1) {
            e_2 = { error: e_2_1 };
        }
        finally {
            try {
                if (_h && !_h.done && (_b = _g.return))
                    _b.call(_g);
            }
            finally {
                if (e_2)
                    throw e_2.error;
            }
        }
        try {
            for (var _j = __values(fromEnum(this.pointerTooltips)), _k = _j.next(); !_k.done; _k = _j.next()) {
                var c = _k.value;
                c.scaleByViewport(this.viewport);
            }
        }
        catch (e_3_1) {
            e_3 = { error: e_3_1 };
        }
        finally {
            try {
                if (_k && !_k.done && (_c = _j.return))
                    _c.call(_j);
            }
            finally {
                if (e_3)
                    throw e_3.error;
            }
        }
        try {
            for (var _l = __values(fromEnum(this.calloutShapes)), _m = _l.next(); !_m.done; _m = _l.next()) {
                var d = _m.value;
                d.scaleByViewport(this.viewport);
            }
        }
        catch (e_4_1) {
            e_4 = { error: e_4_1 };
        }
        finally {
            try {
                if (_m && !_m.done && (_d = _l.return))
                    _d.call(_l);
            }
            finally {
                if (e_4)
                    throw e_4.error;
            }
        }
    };
    SeriesVisualData.prototype.serialize = function () {
        var a = new StringBuilder(0);
        a.u("{");
        if (this.name != null) {
            a.u("name: \"" + this.name + "\",");
        }
        a.u("type: \"" + this.type + "\", ");
        a.u("opacity: " + this.opacity + ", ");
        a.u("viewport: { left: " + this.viewport.left + ", top: " + this.viewport.top + ", width: " + this.viewport.width + ", height: " + this.viewport.height + "}, ");
        a.u("shapes: [");
        for (var b = 0; b < this.shapes.count; b++) {
            if (b != 0) {
                a.l(", ");
            }
            a.l(this.shapes._inner[b].serialize());
        }
        a.u("],");
        a.u("pointerTooltips: [");
        for (var c = 0; c < this.pointerTooltips.count; c++) {
            if (c != 0) {
                a.l(", ");
            }
            a.l(this.pointerTooltips._inner[c].serialize());
        }
        a.u("],");
        if (this.calloutShapes != null && this.calloutShapes.count > 0) {
            a.u("calloutshapes: [");
            for (var d = 0; d < this.calloutShapes.count; d++) {
                if (d != 0) {
                    a.l(", ");
                }
                a.l(this.calloutShapes._inner[d].serialize());
            }
            a.u("],");
        }
        a.u("markerShapes: [");
        for (var e = 0; e < this.markerShapes.count; e++) {
            if (e != 0) {
                a.l(", ");
            }
            a.l(this.markerShapes._inner[e].serialize());
        }
        a.u("]");
        this.n(a);
        if (this.pixels != null) {
            a.u(", pixels: [");
            for (var f = 0; f < this.pixels.length; f++) {
                if (f != 0) {
                    a.l(", ");
                }
                a.l(this.pixels[f].toString());
            }
            a.u("], ");
            a.u("pixelWidth: " + this.pixelWidth + ", ");
        }
        a.u("}");
        return a.toString();
    };
    SeriesVisualData.prototype.n = function (a) {
    };
    SeriesVisualData.$t = markType(SeriesVisualData, 'SeriesVisualData');
    return SeriesVisualData;
}(Base));
export { SeriesVisualData };
//# sourceMappingURL=SeriesVisualData.js.map
