/*
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 } from "tslib";
import { XYChart } from "./XYChart";
import { typeCast, runOn, delegateCombine, enumGetBox, markType, TypeRegistrar, getInstanceType } from "igniteui-angular-core";
import { CategoryChartType_$type } from "./CategoryChartType";
import { CategorySeriesMarkerCollisionAvoidance_$type } from "./CategorySeriesMarkerCollisionAvoidance";
import { CategoryTransitionInMode_$type } from "./CategoryTransitionInMode";
import { TransitionInSpeedType_$type } from "./TransitionInSpeedType";
import { AutoMarginsAndAngleUpdateMode_$type } from "./AutoMarginsAndAngleUpdateMode";
import { AxisRangeBufferMode_$type } from "./AxisRangeBufferMode";
import { CategoryXAxis } from "./CategoryXAxis";
import { List$1 } from "igniteui-angular-core";
import { DataSeriesType_$type } from "igniteui-angular-core";
import { NumericYAxis } from "./NumericYAxis";
import { IDataSeriesAdapterRule_$type } from "igniteui-angular-core";
import { SimpleCategorySeriesRule } from "igniteui-angular-core";
import { SubCollectionsRule } from "igniteui-angular-core";
import { DVContainer } from "igniteui-angular-core";
import { Brush } from "igniteui-angular-core";
import { AxisDefaults } from "./AxisDefaults";
import { Defaults } from "./Defaults";
import { Series } from "./Series";
import { HorizontalAnchoredCategorySeries } from "./HorizontalAnchoredCategorySeries";
import { ArrayExtension } from "igniteui-angular-core";
import { AxisLabelSettings } from "./AxisLabelSettings";
import { DeviceUtils } from "igniteui-angular-core";
import { CategoryChartMockDataGenerator } from "./CategoryChartMockDataGenerator";
import { stringIsNullOrEmpty } from "igniteui-angular-core";
/**
 * @hidden
 */
var CategoryChart = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(CategoryChart, _super);
    function CategoryChart() {
        var _this = _super.call(this) || this;
        _this.akt = 1000;
        _this.aku = 1000;
        _this.aiw = null;
        _this.aix = null;
        _this.aig = 9;
        _this.aii = 1;
        _this.ai2 = false;
        _this.ai3 = true;
        _this.aik = 0;
        _this.aiu = 0;
        _this.ajq = 0;
        _this.ajt = 0;
        _this.ajp = 0;
        _this.ajs = 0;
        _this.ajr = 1;
        _this.aju = 0;
        _this.aj0 = NaN;
        _this.aic = 1;
        _this.ai4 = true;
        _this.ai5 = true;
        _this.ajn = DeviceUtils.g(2);
        _this.ajo = DeviceUtils.g(60);
        _this.ai9 = true;
        _this.ai6 = true;
        _this.ai8 = false;
        _this.aie = 0;
        _this.aja = false;
        _this.akv = 10;
        _this.aj2 = NaN;
        _this.aj1 = NaN;
        _this.aj3 = 0;
        _this.ah8 = null;
        _this.ah9 = null;
        _this.ai7 = true;
        _this.ajv = 3;
        _this.ajw = NaN;
        _this.ajx = NaN;
        _this.ajy = NaN;
        _this.ajz = NaN;
        _this.ai0 = false;
        _this.ai1 = false;
        _this.ajm = null;
        DVContainer.instance.registerIfLoaded("CategoryChartToolbarFactoryManager");
        _this.vc();
        return _this;
    }
    CategoryChart.prototype.vw = function () {
        _super.prototype.vw.call(this);
        if (this.dataChart == null) {
            return;
        }
        var a = this.dataChart.dp.j.e();
        this.aia = a.d;
        this.aib = a.e;
        if (this.ahk == null) {
            this.ahk = a.k;
        }
        if (this.ahr == null) {
            this.ahr = a.k;
        }
        this.adf = 0;
        this.ahs = AxisDefaults.axis_MajorBrush;
        this.ahv = null;
        this.aho = AxisDefaults.axis_LineBrush;
        this.ahl = null;
        this.acw = AxisDefaults.categoryAxis_TickLength;
        this.ahp = AxisDefaults.axis_TickBrush;
        this.acx = AxisDefaults.axis_TickStroke;
        this.crosshairsAnnotationEnabled = true;
        this.gv = true;
        this.crosshairsDisplayMode = 0;
        this.jw = Defaults.crosshairLineThickness;
        this.y9 = Defaults.crosshairLineBrush;
        this.y4 = Defaults.crosshairXAxisAnnotationBackground;
        this.y5 = Defaults.crosshairXAxisAnnotationTextColor;
        this.aje = true;
    };
    CategoryChart.prototype.vy = function (a, b) {
        _super.prototype.vy.call(this, a, b);
        a.ki = this.akw;
        a.kj = this.akx;
        a.df = this.aiy;
        a.dg = this.aiz;
    };
    CategoryChart.prototype.wr = function (a, b, c) {
        var _this = this;
        _super.prototype.wr.call(this, a, b, c);
        switch (a) {
            case "TransitionInDuration":
                this.vl(function (d) { return d.ki = _this.akw; });
                break;
            case "TransitionOutDuration":
                this.vl(function (d) { return d.kj = _this.akx; });
                break;
            case "TransitionInEasingFunction":
                this.vl(function (d) { return d.df = _this.aiy; });
                break;
            case "TransitionOutEasingFunction":
                this.vl(function (d) { return d.dg = _this.aiz; });
                break;
        }
    };
    Object.defineProperty(CategoryChart.prototype, "akw", {
        get: function () {
            return this.akt;
        },
        set: function (a) {
            var b = this.akw;
            if (a != b) {
                this.akt = a;
                this.wn("TransitionInDuration", b, this.akw);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akx", {
        get: function () {
            return this.aku;
        },
        set: function (a) {
            var b = this.akx;
            if (a != b) {
                this.aku = a;
                this.wn("TransitionOutDuration", b, this.akx);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aiy", {
        get: function () {
            return this.aiw;
        },
        set: function (a) {
            var b = this.aiy;
            if (a != b) {
                this.aiw = a;
                this.wn("TransitionInEasingFunction", b, this.aiy);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aiz", {
        get: function () {
            return this.aix;
        },
        set: function (a) {
            var b = this.aiz;
            if (a != b) {
                this.aix = a;
                this.wn("TransitionOutEasingFunction", b, this.aiz);
            }
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.ak3 = function () {
        var cvd_ = this.mc();
        cvd_.scaleByViewport();
        return (cvd_.serialize());
    };
    CategoryChart.prototype.vr = function (a, b) {
        _super.prototype.vr.call(this, a, b);
        a.ez = this.gm;
        a.y8 = this.ajf;
        a.zb = this.ajg;
        a.zy = this.aj4;
        a.zz = this.aj5;
        a.yb = this.aid;
    };
    CategoryChart.prototype.vx = function (a, b) {
        _super.prototype.vx.call(this, a, b);
        var c = typeCast(HorizontalAnchoredCategorySeries.$, a);
        if (c == null) {
            return;
        }
        c.aa9 = this.aij;
        c.zv = this.aje;
        c.zf = this.ail;
        c.c6 = this.aiv;
        c.trendLineBrush = ArrayExtension.getModulus$1(Brush.$, this.af, b);
        c.trendLineType = this.ed;
        c.trendLineThickness = this.kt;
        c.xk = this.c3(a, b);
        if (a.fn) {
            a.sb(ArrayExtension.getModulus$1(Brush.$, this.aia, b), ArrayExtension.getModulus$1(Brush.$, this.aib, b));
        }
    };
    CategoryChart.prototype.aim = function () {
        return new CategoryXAxis();
    };
    CategoryChart.prototype.aiq = function () {
        return new NumericYAxis();
    };
    CategoryChart.prototype.u7 = function () {
        this.xAxis = this.aim();
        this.xAxis.name = "xAxis";
        var a = this.xAxis;
        a.propertyChanged = delegateCombine(a.propertyChanged, runOn(this, this.al7));
        this.yAxis = this.aiq();
        this.yAxis.name = "yAxis";
        var b = this.yAxis;
        b.propertyChanged = delegateCombine(b.propertyChanged, runOn(this, this.al8));
        if (this.xAxis.a3 == null) {
            this.xAxis.a3 = new AxisLabelSettings();
        }
        if (this.yAxis.a3 == null) {
            this.yAxis.a3 = new AxisLabelSettings();
        }
    };
    CategoryChart.prototype.agk = function (a) {
        _super.prototype.agk.call(this, a);
        a.o1 = this.aji;
        a.o6 = this.ajk;
        a.cr = this.ajj;
    };
    CategoryChart.prototype.agi = function (a) {
        _super.prototype.agi.call(this, a);
        a.cr = this.ajh;
        a.zoomMaximumCategoryRange = this.aki;
        a.zoomToCategoryRange = this.akk;
        a.zoomToCategoryStart = this.akl;
        a.zoomMaximumItemSpan = this.akj;
        a.zoomToItemSpan = this.akm;
    };
    CategoryChart.prototype.get_cc = function () {
        return 0;
    };
    Object.defineProperty(CategoryChart.prototype, "cc", {
        get: function () {
            return this.get_cc();
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aih", {
        get: function () {
            return this.aig;
        },
        set: function (a) {
            if (a != this.aig) {
                var b = this.aih;
                this.aig = a;
                this.wn("ChartType", enumGetBox(CategoryChartType_$type, b), enumGetBox(CategoryChartType_$type, this.aih));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aij", {
        get: function () {
            return this.aii;
        },
        set: function (a) {
            var b = this.aij;
            if (a != b) {
                this.aii = a;
                this.wn("MarkerCollisionAvoidance", enumGetBox(CategorySeriesMarkerCollisionAvoidance_$type, b), enumGetBox(CategorySeriesMarkerCollisionAvoidance_$type, this.aij));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajd", {
        get: function () {
            return this.ai2;
        },
        set: function (a) {
            var b = this.ajd;
            if (a != b) {
                this.ai2 = a;
                this.wn("IsSplineShapePartOfRange", b, this.ajd);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aje", {
        get: function () {
            return this.ai3;
        },
        set: function (a) {
            var b = this.aje;
            if (a != b) {
                this.ai3 = a;
                this.wn("IsTransitionInEnabled", b, this.aje);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ail", {
        get: function () {
            return this.aik;
        },
        set: function (a) {
            var b = this.ail;
            if (a != b) {
                this.aik = a;
                this.wn("TransitionInMode", enumGetBox(CategoryTransitionInMode_$type, b), enumGetBox(CategoryTransitionInMode_$type, this.ail));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aiv", {
        get: function () {
            return this.aiu;
        },
        set: function (a) {
            var b = this.aiv;
            if (a != b) {
                this.aiu = a;
                this.wn("TransitionInSpeedType", enumGetBox(TransitionInSpeedType_$type, b), enumGetBox(TransitionInSpeedType_$type, this.aiv));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akd", {
        get: function () {
            return this.ajq;
        },
        set: function (a) {
            var b = this.akd;
            if (a != b) {
                this.ajq = a;
                this.wn("XAxisInterval", b, this.akd);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akg", {
        get: function () {
            return this.ajt;
        },
        set: function (a) {
            var b = this.akg;
            if (a != b) {
                this.ajt = a;
                this.wn("XAxisMinorInterval", b, this.akg);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akc", {
        get: function () {
            return this.ajp;
        },
        set: function (a) {
            var b = this.akc;
            if (a != b) {
                this.ajp = a;
                this.wn("XAxisGap", b, this.akc);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akf", {
        get: function () {
            return this.ajs;
        },
        set: function (a) {
            var b = this.akf;
            if (a != b) {
                this.ajs = a;
                this.wn("XAxisMinimumGapSize", b, this.akf);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ake", {
        get: function () {
            return this.ajr;
        },
        set: function (a) {
            var b = this.ake;
            if (a != b) {
                this.ajr = a;
                this.wn("XAxisMaximumGap", b, this.ake);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akh", {
        get: function () {
            return this.aju;
        },
        set: function (a) {
            var b = this.akh;
            if (a != b) {
                this.aju = a;
                this.wn("XAxisOverlap", b, this.akh);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akp", {
        get: function () {
            return this.aj0;
        },
        set: function (a) {
            var b = this.akp;
            if (a != b) {
                this.aj0 = a;
                this.wn("YAxisInterval", b, this.akp);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aid", {
        get: function () {
            return this.aic;
        },
        set: function (a) {
            var b = this.aid;
            if (a != b) {
                this.aic = a;
                this.wn("AutoMarginAndAngleUpdateMode", enumGetBox(AutoMarginsAndAngleUpdateMode_$type, b), enumGetBox(AutoMarginsAndAngleUpdateMode_$type, this.aid));
            }
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.al9 = function () {
        if (this.dataChart != null) {
            this.dataChart.abj();
        }
    };
    Object.defineProperty(CategoryChart.prototype, "ajf", {
        get: function () {
            return this.ai4;
        },
        set: function (a) {
            var b = this.ajf;
            if (a != b) {
                this.ai4 = a;
                this.wn("ShouldAutoExpandMarginForInitialLabels", b, this.ajf);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajg", {
        get: function () {
            return this.ai5;
        },
        set: function (a) {
            var b = this.ajg;
            if (a != b) {
                this.ai5 = a;
                this.wn(CategoryChart.alc, b, this.ajg);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aj4", {
        get: function () {
            return this.ajn;
        },
        set: function (a) {
            var b = this.aj4;
            if (a != b) {
                this.ajn = a;
                this.wn("AutoExpandMarginExtraPadding", b, this.aj4);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aj5", {
        get: function () {
            return this.ajo;
        },
        set: function (a) {
            var b = this.aj5;
            if (a != b) {
                this.ajo = a;
                this.wn("AutoExpandMarginMaximumValue", b, this.aj5);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajk", {
        get: function () {
            return this.ai9;
        },
        set: function (a) {
            var b = this.ajk;
            if (a != b) {
                this.ai9 = a;
                this.wn("YAxisFavorLabellingScaleEnd", b, this.ajk);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajh", {
        get: function () {
            return this.ai6;
        },
        set: function (a) {
            var b = this.ajh;
            if (a != b) {
                this.ai6 = a;
                this.wn(CategoryChart.alj, b, this.ajh);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajj", {
        get: function () {
            return this.ai8;
        },
        set: function (a) {
            var b = this.ajj;
            if (a != b) {
                this.ai8 = a;
                this.wn(CategoryChart.alx, b, this.ajj);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aif", {
        get: function () {
            return this.aie;
        },
        set: function (a) {
            var b = this.aif;
            if (a != b) {
                this.aie = a;
                this.wn("YAxisAutoRangeBufferMode", enumGetBox(AxisRangeBufferMode_$type, b), enumGetBox(AxisRangeBufferMode_$type, this.aif));
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajl", {
        get: function () {
            return this.aja;
        },
        set: function (a) {
            var b = this.ajl;
            if (a != b) {
                this.aja = a;
                this.wn("YAxisIsLogarithmic", b, this.ajl);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aky", {
        get: function () {
            return this.akv;
        },
        set: function (a) {
            var b = this.aky;
            if (a != b) {
                this.akv = a;
                this.wn("YAxisLogarithmBase", b, this.aky);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akr", {
        get: function () {
            return this.aj2;
        },
        set: function (a) {
            var b = this.akr;
            if (a != b) {
                this.aj2 = a;
                this.wn("YAxisMinimumValue", b, this.akr);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akq", {
        get: function () {
            return this.aj1;
        },
        set: function (a) {
            var b = this.akq;
            if (a != b) {
                this.aj1 = a;
                this.wn("YAxisMaximumValue", b, this.akq);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aks", {
        get: function () {
            return this.aj3;
        },
        set: function (a) {
            var b = this.aks;
            if (a != b) {
                this.aj3 = a;
                this.wn("YAxisMinorInterval", b, this.aks);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akb", {
        get: function () {
            return this.xAxis.qp;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aka", {
        get: function () {
            return this.xAxis.qo;
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.aj7 = function () {
        return this.akb;
    };
    CategoryChart.prototype.aj9 = function () {
        return this.ako;
    };
    CategoryChart.prototype.aj6 = function () {
        return this.aka;
    };
    CategoryChart.prototype.aj8 = function () {
        return this.akn;
    };
    Object.defineProperty(CategoryChart.prototype, "ako", {
        get: function () {
            return this.yAxis.pr;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akn", {
        get: function () {
            return this.yAxis.pq;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aia", {
        get: function () {
            return this.ah8;
        },
        set: function (a) {
            var b = this.aia;
            if (a != b) {
                this.ah8 = a;
                this.wn("NegativeBrushes", b, this.aia);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aib", {
        get: function () {
            return this.ah9;
        },
        set: function (a) {
            var b = this.aib;
            if (a != b) {
                this.ah9 = a;
                this.wn("NegativeOutlines", b, this.aib);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aji", {
        get: function () {
            return this.ai7;
        },
        set: function (a) {
            var b = this.aji;
            if (a != b) {
                this.ai7 = a;
                this.wn("YAxisAbbreviateLargeNumbers", b, this.aji);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "aki", {
        get: function () {
            return this.ajv;
        },
        set: function (a) {
            var b = this.aki;
            if (a != b) {
                this.ajv = a;
                this.wn("XAxisZoomMaximumCategoryRange", b, this.aki);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akj", {
        get: function () {
            return this.ajw;
        },
        set: function (a) {
            var b = this.akj;
            if (a != b) {
                this.ajw = a;
                this.wn("XAxisZoomMaximumItemSpan", b, this.akj);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akk", {
        get: function () {
            return this.ajx;
        },
        set: function (a) {
            var b = this.akk;
            if (a != b) {
                this.ajx = a;
                this.wn("XAxisZoomToCategoryRange", b, this.akk);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akl", {
        get: function () {
            return this.ajy;
        },
        set: function (a) {
            var b = this.akl;
            if (a != b) {
                this.ajy = a;
                this.wn("XAxisZoomToCategoryStart", b, this.akl);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "akm", {
        get: function () {
            return this.ajz;
        },
        set: function (a) {
            var b = this.akm;
            if (a != b) {
                this.ajz = a;
                this.wn("XAxisZoomToItemSpan", b, this.akm);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajb", {
        get: function () {
            return this.ai0;
        },
        set: function (a) {
            var b = this.ajb;
            if (a != b) {
                this.ai0 = a;
                this.wn("IsCategoryHighlightingEnabled", b, this.ajb);
            }
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "ajc", {
        get: function () {
            return this.ai1;
        },
        set: function (a) {
            var b = this.ajc;
            if (a != b) {
                this.ai1 = a;
                this.wn("IsItemHighlightingEnabled", b, this.ajc);
            }
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.get_h7 = function () {
        var a = new List$1(DataSeriesType_$type, 0);
        if (TypeRegistrar.isRegistered("AreaSeries")) {
            a.add(2);
        }
        if (TypeRegistrar.isRegistered("ColumnSeries")) {
            a.add(1);
        }
        if (TypeRegistrar.isRegistered("LineSeries")) {
            a.add(0);
        }
        if (TypeRegistrar.isRegistered("PointSeries")) {
            a.add(10);
        }
        if (TypeRegistrar.isRegistered("SplineSeries")) {
            a.add(6);
        }
        if (TypeRegistrar.isRegistered("SplineAreaSeries")) {
            a.add(7);
        }
        if (TypeRegistrar.isRegistered("StepAreaSeries")) {
            a.add(5);
        }
        if (TypeRegistrar.isRegistered("StepLineSeries")) {
            a.add(4);
        }
        if (TypeRegistrar.isRegistered("WaterfallSeries")) {
            a.add(8);
        }
        return a;
    };
    Object.defineProperty(CategoryChart.prototype, "h7", {
        get: function () {
            return this.get_h7();
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.id = function () {
        if (this.ajm == null) {
            this.ajm = CategoryChartMockDataGenerator.a();
        }
        return this.ajm;
    };
    CategoryChart.prototype.c2 = function (a) {
        if (a != null) {
            var b = _super.prototype.c2.call(this, a);
            if (b == 2) {
                if (a.fm && this.g6) {
                    return 13;
                }
            }
        }
        return _super.prototype.c2.call(this, a);
    };
    CategoryChart.prototype.c4 = function (a) {
        if (a != null) {
            var b = _super.prototype.c2.call(this, a);
            if (b == 2) {
                if (a.fm && this.g6) {
                    return 13;
                }
            }
        }
        return _super.prototype.c4.call(this, a);
    };
    CategoryChart.prototype.get_hp = function () {
        return true;
    };
    CategoryChart.prototype.al7 = function (a, b) {
        switch (b.propertyName) {
            case "ActualMinimum":
                this.w6("XAxisActualMinimum");
                break;
            case "ActualMaximum":
                this.w6("XAxisActualMaximum");
                break;
        }
    };
    CategoryChart.prototype.al8 = function (a, b) {
        switch (b.propertyName) {
            case "ActualMinimumValue":
                this.w6("YAxisActualMinimum");
                break;
            case "ActualMaximumValue":
                this.w6("YAxisActualMaximum");
                break;
        }
    };
    CategoryChart.prototype.xl = function () {
        _super.prototype.xl.call(this);
        this.xAxis.hg = this.adp == null ? XYChart.ad1(this.xAxis, this.bg.dataSeries) : this.adp;
        this.xAxis.itemsSource = this.dataChart != null && this.dataChart.series.count > 0 ? this.dataChart.series._inner[0].itemsSource : null;
        if (this.ajf) {
            this.wb(function (a) { return a.abj(); });
        }
    };
    Object.defineProperty(CategoryChart.prototype, "xAxis", {
        get: function () {
            return this._xAxis;
        },
        set: function (a) {
            this._xAxis = a;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(CategoryChart.prototype, "yAxis", {
        get: function () {
            return this._yAxis;
        },
        set: function (a) {
            this._yAxis = a;
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.aip = function (a, b) {
        switch (a) {
            case 2: return this.dg(1);
            case 3: return this.dg(10);
            case 0: return this.dg(0);
            case 1: return this.dg(2);
            case 6: return this.dg(6);
            case 7: return this.dg(7);
            case 4: return this.dg(4);
            case 5: return this.dg(5);
            case 8: return this.dg(8);
            case 9: return this.aio(b);
            default: return this.dg(1);
        }
    };
    CategoryChart.prototype.aio = function (a) {
        return this.dg(a);
    };
    CategoryChart.prototype.bf = function (a) {
        switch (this.aih) {
            case 1: return 2;
            case 0: return 0;
            case 3: return 10;
            case 6: return 6;
            case 7: return 7;
            case 5: return 5;
            case 4: return 4;
            case 8: return 8;
            case 9: return a.suggestedSeries;
            default:
            case 2: return 1;
        }
    };
    CategoryChart.prototype.dd = function (a, b) {
        var c = this.aip(this.aih, a.suggestedSeries);
        c.abz = a.findMatchingHint(0).path;
        c.xAxis = this.xAxis;
        c.yAxis = this.yAxis;
        return c;
    };
    CategoryChart.prototype.xj = function (a) {
        if (a.suggestedSecondaryAxis == 2) {
            this.yAxis.pb = true;
            this.yAxis.qe = 10;
        }
    };
    CategoryChart.prototype.xm = function () {
        this.yAxis.pb = this.ajl;
        this.yAxis.qe = this.aky;
    };
    CategoryChart.prototype.get_h6 = function () {
        return ((function () {
            var $ret = new List$1(IDataSeriesAdapterRule_$type, 0);
            $ret.add(new SimpleCategorySeriesRule());
            $ret.add(new SubCollectionsRule());
            return $ret;
        })());
    };
    Object.defineProperty(CategoryChart.prototype, "h6", {
        get: function () {
            return this.get_h6();
        },
        enumerable: false,
        configurable: true
    });
    CategoryChart.prototype.u1 = function (a, b) {
        var c = typeCast(HorizontalAnchoredCategorySeries.$, a);
        if (c != null) {
            c.aa9 = this.aij;
            c.xk = this.c3(a, b);
        }
    };
    CategoryChart.prototype.al5 = function (a) {
        this.al6(function (b, c) { return a(b); });
    };
    CategoryChart.prototype.al6 = function (a) {
        if (this.dataChart == null) {
            return;
        }
        for (var b = 0; b < this.dataChart.series.count; b++) {
            var c = typeCast(HorizontalAnchoredCategorySeries.$, this.dataChart.series._inner[b]);
            if (c == null) {
                continue;
            }
            a(c, b);
        }
    };
    CategoryChart.prototype.aaz = function () {
        return this.xAxis;
    };
    CategoryChart.prototype.aa0 = function () {
        return this.yAxis;
    };
    CategoryChart.prototype.ais = function () {
        return this.dg(30);
    };
    CategoryChart.prototype.ait = function () {
        return this.dg(31);
    };
    CategoryChart.prototype.h3 = function (a, b) {
        var c = _super.prototype.h3.call(this, a, b);
        if (c != null) {
            var d = new List$1(Series.$, 0);
            if (this.ai0) {
                d.add(this.ais());
            }
            if (this.ai1) {
                d.add(this.ait());
            }
            for (var e = 0; e < d.count; e++) {
                var f = d._inner[e];
                f.name = a + getInstanceType(f).typeName;
                c.add(f);
            }
        }
        return c;
    };
    CategoryChart.prototype.bb = function () {
        if (this.ba == 0) {
            return 1;
        }
        else {
            return this.ba;
        }
    };
    CategoryChart.prototype.xq = function (a, b, c) {
        _super.prototype.xq.call(this, a, b, c);
        if (this.bg.dataSeries.count > 0) {
            if (stringIsNullOrEmpty(this.n6)) {
                this.cf.setXMemberPath(a, c.getMemberPathFor(16));
            }
            if (stringIsNullOrEmpty(this.n8)) {
                this.cf.setYMemberPath(a, c.getMemberPathFor(0));
            }
            if (stringIsNullOrEmpty(this.nt)) {
                this.cf.setLabelMemberPath(a, c.getMemberPathFor(0));
            }
            if (stringIsNullOrEmpty(this.np)) {
                this.cf.setContentMemberPath(a, c.getMemberPathFor(0));
            }
        }
    };
    CategoryChart.prototype.g9 = function () {
        if (this.crosshairsDisplayMode == 4 || this.crosshairsDisplayMode == 3) {
            return true;
        }
        else if (this.crosshairsDisplayMode == 0) {
            if (this.aih == 2 || this.aih == 8) {
                return false;
            }
            else if (this.aih == 9 && this.bg != null && this.bg.dataSeries != null && this.bg.dataSeries.count > 0) {
                var a = this.bg.dataSeries._inner[0].suggestedSeries;
                if (a == 1 || a == 8) {
                    return false;
                }
            }
            return true;
        }
        return false;
    };
    CategoryChart.prototype.get_hg = function () {
        return DVContainer.instance.checkLoaded("CategoryChartToolbarFactoryManager");
    };
    CategoryChart.prototype.wn = function (a, b, c) {
        var _this = this;
        _super.prototype.wn.call(this, a, b, c);
        switch (a) {
            case "ChartType":
                this.vi();
                break;
            case "MarkerCollisionAvoidance":
                this.al5(function (d) { return d.aa9 = _this.aij; });
                break;
            case "IsTransitionInEnabled":
                this.al5(function (d) { return d.zv = _this.aje; });
                break;
            case "IsSplineShapePartOfRange":
                this.al5(function (d) {
                    if (d.f1) {
                        d.sc(_this.ajd);
                    }
                });
                break;
            case "TransitionInMode":
                this.al5(function (d) { return d.zf = _this.ail; });
                break;
            case "TransitionInSpeedType":
                this.al5(function (d) { return d.c6 = _this.aiv; });
                break;
            case "XAxisInterval":
                this.xAxis.qk = this.akd;
                break;
            case "XAxisMinorInterval":
                this.xAxis.ql = this.akg;
                break;
            case "XAxisGap":
                this.xAxis.or = this.akc;
                break;
            case "XAxisOverlap":
                this.xAxis.o0 = this.akh;
                break;
            case "XAxisMinimumGapSize":
                this.xAxis.oz = this.akf;
                break;
            case "XAxisMaximumGap":
                this.xAxis.oy = this.ake;
                break;
            case "XAxisZoomMaximumCategoryRange":
                this.xAxis.zoomMaximumCategoryRange = this.aki;
                break;
            case "XAxisZoomMaximumItemSpan":
                this.xAxis.zoomMaximumItemSpan = this.akj;
                break;
            case "XAxisZoomToCategoryRange":
                this.xAxis.zoomToCategoryRange = this.akk;
                break;
            case "XAxisZoomToCategoryStart":
                this.xAxis.zoomToCategoryStart = this.akl;
                break;
            case "XAxisZoomToItemSpan":
                this.xAxis.zoomToItemSpan = this.akm;
                break;
            case "YAxisInterval":
                this.yAxis.pz = this.akp;
                break;
            case "YAxisFavorLabellingScaleEnd":
                this.yAxis.o6 = this.ajk;
                break;
            case "YAxisAutoRangeBufferMode":
                this.yAxis.ok = this.aif;
                break;
            case "YAxisIsLogarithmic":
                this.yAxis.pb = this.ajl;
                break;
            case "YAxisLogarithmBase":
                this.yAxis.qe = this.aky;
                break;
            case "YAxisMinimumValue":
                this.yAxis.p3 = this.akr;
                break;
            case "YAxisMaximumValue":
                this.yAxis.p2 = this.akq;
                break;
            case "YAxisMinorInterval":
                this.yAxis.p4 = this.aks;
                break;
            case "NegativeBrushes":
            case "NegativeOutlines":
                this.al6(function (d, e) {
                    if (d.fn) {
                        d.sb(ArrayExtension.getModulus$1(Brush.$, _this.aia, e), ArrayExtension.getModulus$1(Brush.$, _this.aib, e));
                    }
                });
                break;
            case "YAxisAbbreviateLargeNumbers":
                this.agr(function (d) { return d.o1 = _this.aji; });
                break;
            case "IsCategoryHighlightingEnabled":
            case "IsItemHighlightingEnabled":
                this.vi();
                break;
            case "AutoMarginAndAngleUpdateMode":
                this.wb(function (d) { return d.yb = _this.aid; });
                break;
            case "ShouldAutoExpandMarginForInitialLabels":
                this.wb(function (d) { return d.y8 = _this.ajf; });
                break;
            case CategoryChart.alc:
                this.wb(function (d) { return d.zb = _this.ajg; });
                break;
            case "AutoExpandMarginExtraPadding":
                this.wb(function (d) { return d.zy = _this.aj4; });
                break;
            case "AutoExpandMarginMaximumValue":
                this.wb(function (d) { return d.zz = _this.aj5; });
                break;
            case CategoryChart.alj:
                this.agn(function (d) { return d.cr = _this.ajh; }, a);
                break;
            case CategoryChart.alx:
                this.agr(function (d) { return d.cr = _this.ajj; });
                break;
        }
    };
    CategoryChart.$t = markType(CategoryChart, 'CategoryChart', XYChart.$);
    CategoryChart.alc = "ShouldConsiderAutoRotationForInitialLabels";
    CategoryChart.alj = "XAxisEnhancedIntervalPreferMoreCategoryLabels";
    CategoryChart.alx = "YAxisEnhancedIntervalPreferMoreCategoryLabels";
    return CategoryChart;
}(XYChart));
export { CategoryChart };
