/*
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 * as tslib_1 from "tslib";
import { Base, toNullable, Boolean_$type, fromEnum, typeCast, markType, getInstanceType } from "igniteui-angular-core";
import { ISupportSetProperty_$type } from "./ISupportSetProperty";
import { CT_ShapeNonVisual } from "./CT_ShapeNonVisual";
import { CT_ShapeProperties_DML } from "./CT_ShapeProperties_DML";
import { CT_ShapeStyle } from "./CT_ShapeStyle";
import { CT_TextBody_DML } from "./CT_TextBody_DML";
import { ST_OnOff } from "./ST_OnOff";
/**
 * @hidden
 */
var CT_Shape_ChartDrawing = /** @class */ (function (_super) {
    tslib_1.__extends(CT_Shape_ChartDrawing, _super);
    function CT_Shape_ChartDrawing() {
        var _this = _super.call(this) || this;
        _this.o = null;
        _this.p = null;
        _this.k = toNullable(Boolean_$type, null);
        _this.l = toNullable(Boolean_$type, null);
        _this.e = null;
        _this.a = null;
        _this.g = null;
        _this.c = null;
        return _this;
    }
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "q", {
        get: function () {
            return this.o;
        },
        set: function (a) {
            this.o = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "r", {
        get: function () {
            return this.p;
        },
        set: function (a) {
            this.p = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "m", {
        get: function () {
            return this.k;
        },
        set: function (a) {
            this.k = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "n", {
        get: function () {
            return this.l;
        },
        set: function (a) {
            this.l = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "f", {
        get: function () {
            return this.e;
        },
        set: function (a) {
            this.e = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "b", {
        get: function () {
            return this.a;
        },
        set: function (a) {
            this.a = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "h", {
        get: function () {
            return this.g;
        },
        set: function (a) {
            this.g = a;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(CT_Shape_ChartDrawing.prototype, "d", {
        get: function () {
            return this.c;
        },
        set: function (a) {
            this.c = a;
        },
        enumerable: true,
        configurable: true
    });
    CT_Shape_ChartDrawing.t = function (a, b, c, d, e) {
        var e_1, _a;
        b = null;
        c = null;
        d = toNullable(Boolean_$type, null);
        e = toNullable(Boolean_$type, null);
        try {
            for (var _b = tslib_1.__values(fromEnum(a.ab.u)), _c = _b.next(); !_c.done; _c = _b.next()) {
                var f = _c.value;
                switch (f.a.e(a.d)) {
                    case "macro":
                        b = f.d;
                        break;
                    case "textlink":
                        c = f.d;
                        break;
                    case "fLocksText":
                        d = toNullable(Boolean_$type, ST_OnOff.e(f.d));
                        break;
                    case "fPublished":
                        e = toNullable(Boolean_$type, ST_OnOff.e(f.d));
                        break;
                    default: break;
                }
            }
        }
        catch (e_1_1) { e_1 = { error: e_1_1 }; }
        finally {
            try {
                if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
            }
            finally { if (e_1) throw e_1.error; }
        }
        ;
        return {
            p1: b,
            p2: c,
            p3: d,
            p4: e
        };
    };
    CT_Shape_ChartDrawing.u = function (a, b, c, d, e, f) {
        if (c === void 0) { c = toNullable(Boolean_$type, null); }
        if (d === void 0) { d = toNullable(Boolean_$type, null); }
        if (e === void 0) { e = null; }
        if (f === void 0) { f = null; }
        a.ad.p(b, "cd");
        var g = null;
        var h = null;
        if (c.hasValue) {
            h = "fLocksText";
            g = ST_OnOff.g(c.value);
            a.ad.h(h, g);
        }
        if (d.hasValue) {
            h = "fPublished";
            g = ST_OnOff.g(d.value);
            a.ad.h(h, g);
        }
        if (e != null) {
            h = "macro";
            g = e;
            a.ad.h(h, g);
        }
        if (f != null) {
            h = "textlink";
            g = f;
            a.ad.h(h, g);
        }
        ;
    };
    CT_Shape_ChartDrawing.prototype.setProperty = function (a, b) {
        switch (a) {
            case 1106:
                this.f = typeCast(CT_ShapeNonVisual.$, b);
                break;
            case 1570:
                this.b = typeCast(CT_ShapeProperties_DML.$, b);
                break;
            case 1618:
                this.h = typeCast(CT_ShapeStyle.$, b);
                break;
            case 1777:
                this.d = typeCast(CT_TextBody_DML.$, b);
                break;
            default: break;
        }
    };
    CT_Shape_ChartDrawing.prototype.toString = function () {
        var a = getInstanceType(this);
        return a != null ? a.typeName : _super.prototype.toString.call(this);
    };
    CT_Shape_ChartDrawing.$t = markType(CT_Shape_ChartDrawing, 'CT_Shape_ChartDrawing', Base.$, [ISupportSetProperty_$type]);
    return CT_Shape_ChartDrawing;
}(Base));
export { CT_Shape_ChartDrawing };
//# sourceMappingURL=CT_Shape_ChartDrawing.js.map