import { EventEmitter, Output, Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { delegateCombine } from "igniteui-angular-core";
import { IgxNumericXAxisComponent } from "./igx-numeric-x-axis-component";
import { IgxNumericYAxisComponent } from "./igx-numeric-y-axis-component";
import { IgxProgressiveLoadStatusEventArgs } from "./igx-progressive-load-status-event-args";
import { IgxSeriesComponent } from "./igx-series-component";
import { HighDensityScatterSeries } from "./HighDensityScatterSeries";
import { ensureBool, colorToString, stringToColor, toPoint } from "igniteui-angular-core";
import * as i0 from "@angular/core";
/**
 * Represents a IgxDataChartComponent series where a high volume of scatter points can be displayed.
*/
export let IgxHighDensityScatterSeriesComponent = /*@__PURE__*/ (() => {
    class IgxHighDensityScatterSeriesComponent extends IgxSeriesComponent {
        constructor() {
            super();
            this._progressiveLoadStatusChanged = null;
        }
        createImplementation() {
            return new HighDensityScatterSeries();
        }
        /**
                                     * @hidden
                                     */
        get i() {
            return this._implementation;
        }
        /**
         * Gets whether the current series shows pixels.
        */
        get isPixel() {
            return this.i.d5;
        }
        /**
         * Checks if this series is a scatter series
        */
        get isScatter() {
            return this.i.ec;
        }
        /**
         * Gets or sets the effective x-axis for the current object.
        */
        get xAxis() {
            if (this.i.qa == null) {
                return null;
            }
            if (!this.i.qa.externalObject) {
                let e = IgxNumericXAxisComponent._createFromInternal(this.i.qa);
                if (e) {
                    e._implementation = this.i.qa;
                }
                this.i.qa.externalObject = e;
            }
            return this.i.qa.externalObject;
        }
        set xAxis(v) {
            if (v != null && this._stylingContainer && v._styling)
                v._styling(this._stylingContainer, this, this);
            v == null ? this.i.qa = null : this.i.qa = v.i;
        }
        /**
         * Gets or sets the effective y-axis for the current object.
        */
        get yAxis() {
            if (this.i.qc == null) {
                return null;
            }
            if (!this.i.qc.externalObject) {
                let e = IgxNumericYAxisComponent._createFromInternal(this.i.qc);
                if (e) {
                    e._implementation = this.i.qc;
                }
                this.i.qc.externalObject = e;
            }
            return this.i.qc.externalObject;
        }
        set yAxis(v) {
            if (v != null && this._stylingContainer && v._styling)
                v._styling(this._stylingContainer, this, this);
            v == null ? this.i.qc = null : this.i.qc = v.i;
        }
        /**
         * Gets or sets the x value mapping property for the current series object.
        */
        get xMemberPath() {
            return this.i.sd;
        }
        set xMemberPath(v) {
            this.i.sd = v;
        }
        /**
         * Gets or sets the label displayed before series X value in the Data Legend.
        */
        get xMemberAsLegendLabel() {
            return this.i.r9;
        }
        set xMemberAsLegendLabel(v) {
            this.i.r9 = v;
        }
        /**
         * Gets or sets the label displayed before series Y value in the Data Legend.
        */
        get yMemberAsLegendLabel() {
            return this.i.sh;
        }
        set yMemberAsLegendLabel(v) {
            this.i.sh = v;
        }
        /**
         * Gets or sets the unit after displayed after series X value in the Data Legend.
        */
        get xMemberAsLegendUnit() {
            return this.i.sb;
        }
        set xMemberAsLegendUnit(v) {
            this.i.sb = v;
        }
        /**
         * Gets or sets the unit after displayed after series Y value in the Data Legend.
        */
        get yMemberAsLegendUnit() {
            return this.i.sj;
        }
        set yMemberAsLegendUnit(v) {
            this.i.sj = v;
        }
        /**
         * Gets or sets the y value mapping property for the current series object.
        */
        get yMemberPath() {
            return this.i.sl;
        }
        set yMemberPath(v) {
            this.i.sl = v;
        }
        /**
         * Gets or sets the whether to use use brute force mode.
        */
        get useBruteForce() {
            return this.i.qq;
        }
        set useBruteForce(v) {
            this.i.qq = ensureBool(v);
        }
        /**
         * Gets or sets the whether to progressively load the data into the chart.
        */
        get progressiveLoad() {
            return this.i.qp;
        }
        set progressiveLoad(v) {
            this.i.qp = ensureBool(v);
        }
        /**
         * Gets or sets the density value that maps to the minimum heat color.
        */
        get heatMinimum() {
            return this.i.rl;
        }
        set heatMinimum(v) {
            this.i.rl = +v;
        }
        /**
         * Gets or sets the value that maps to the maximum heat color.
        */
        get heatMaximum() {
            return this.i.rk;
        }
        set heatMaximum(v) {
            this.i.rk = +v;
        }
        /**
         * Gets or sets the color to use for the minimum end of the scale.
        */
        get heatMinimumColor() {
            return colorToString(this.i.tj);
        }
        set heatMinimumColor(v) {
            this.i.tj = stringToColor(v);
        }
        /**
         * Gets or sets the color to use for the maximum end of the scale.
        */
        get heatMaximumColor() {
            return colorToString(this.i.ti);
        }
        set heatMaximumColor(v) {
            this.i.ti = stringToColor(v);
        }
        /**
         * Gets or sets the the pixel extent of the square data points that are rendered.
        */
        get pointExtent() {
            return this.i.rx;
        }
        set pointExtent(v) {
            this.i.rx = +v;
        }
        /**
         * Represents the current status of the progressive load of the series. It will range from 0 to 100, where 100 is fully loaded.
        */
        get progressiveStatus() {
            return this.i.ry;
        }
        set progressiveStatus(v) {
            this.i.ry = +v;
        }
        findByName(name) {
            var baseResult = super.findByName(name);
            if (baseResult) {
                return baseResult;
            }
            if (this.xAxis && this.xAxis.name && this.xAxis.name == name) {
                return this.xAxis;
            }
            if (this.yAxis && this.yAxis.name && this.yAxis.name == name) {
                return this.yAxis;
            }
            return null;
        }
        _styling(container, component, parent) {
            super._styling(container, component, parent);
            this._inStyling = true;
            if (this.xAxis && this.xAxis._styling) {
                this.xAxis._styling(container, component, this);
            }
            if (this.yAxis && this.yAxis._styling) {
                this.yAxis._styling(container, component, this);
            }
            this._inStyling = false;
        }
        getItemValue(item, memberPathName) {
            let iv = this.i.hw(item, memberPathName);
            return (iv);
        }
        /**
         * Determine if object can be used as YAxis
        
        * @param axis  * The object to check
        */
        canUseAsYAxis(axis) {
            let iv = this.i.qo(axis);
            return (iv);
        }
        /**
         * Determine if object can be used as XAxis
        
        * @param axis  * The object to check
        */
        canUseAsXAxis(axis) {
            let iv = this.i.qn(axis);
            return (iv);
        }
        /**
         * Scrolls the series to display the item for the specified data item.
         * The series is scrolled by the minimum amount required to place the specified data item within
         * the central 80% of the visible axis.
        
        * @param item  * The data item (item) to scroll to.
        */
        scrollIntoView(item) {
            let iv = this.i.en(item);
            return (iv);
        }
        /**
         * Gets the item that is the best match for the specified world coordinates.
        
        * @param world  * The world coordinates to use.
        */
        getItem(world) {
            let iv = this.i.ht(toPoint(world));
            return (iv);
        }
        /**
         * Raised when the progressive loading state of the series has changed.
        */
        get progressiveLoadStatusChanged() {
            if (this._progressiveLoadStatusChanged == null) {
                this._progressiveLoadStatusChanged = new EventEmitter();
                this.i.progressiveLoadStatusChanged = delegateCombine(this.i.progressiveLoadStatusChanged, (o, e) => {
                    this._runInZone(() => {
                        let outerArgs = new IgxProgressiveLoadStatusEventArgs();
                        outerArgs._provideImplementation(e);
                        if (this.beforeProgressiveLoadStatusChanged) {
                            this.beforeProgressiveLoadStatusChanged(this, outerArgs);
                        }
                        this._progressiveLoadStatusChanged.emit({
                            sender: this,
                            args: outerArgs
                        });
                    });
                });
            }
            return this._progressiveLoadStatusChanged;
        }
    }
    IgxHighDensityScatterSeriesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.14", ngImport: i0, type: IgxHighDensityScatterSeriesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
    IgxHighDensityScatterSeriesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.14", type: IgxHighDensityScatterSeriesComponent, selector: "igx-high-density-scatter-series", inputs: { xAxis: "xAxis", yAxis: "yAxis", xMemberPath: "xMemberPath", xMemberAsLegendLabel: "xMemberAsLegendLabel", yMemberAsLegendLabel: "yMemberAsLegendLabel", xMemberAsLegendUnit: "xMemberAsLegendUnit", yMemberAsLegendUnit: "yMemberAsLegendUnit", yMemberPath: "yMemberPath", useBruteForce: "useBruteForce", progressiveLoad: "progressiveLoad", heatMinimum: "heatMinimum", heatMaximum: "heatMaximum", heatMinimumColor: "heatMinimumColor", heatMaximumColor: "heatMaximumColor", pointExtent: "pointExtent", progressiveStatus: "progressiveStatus" }, outputs: { progressiveLoadStatusChanged: "progressiveLoadStatusChanged" }, providers: [{ provide: IgxSeriesComponent, useExisting: forwardRef(() => IgxHighDensityScatterSeriesComponent) }], usesInheritance: true, ngImport: i0, template: ``, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
    return IgxHighDensityScatterSeriesComponent;
})();
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.14", ngImport: i0, type: IgxHighDensityScatterSeriesComponent, decorators: [{
            type: Component,
            args: [{
                    selector: 'igx-high-density-scatter-series',
                    template: ``,
                    providers: [{ provide: IgxSeriesComponent, useExisting: forwardRef(() => IgxHighDensityScatterSeriesComponent) }],
                    changeDetection: ChangeDetectionStrategy.OnPush
                }]
        }], ctorParameters: function () { return []; }, propDecorators: { xAxis: [{
                type: Input
            }], yAxis: [{
                type: Input
            }], xMemberPath: [{
                type: Input
            }], xMemberAsLegendLabel: [{
                type: Input
            }], yMemberAsLegendLabel: [{
                type: Input
            }], xMemberAsLegendUnit: [{
                type: Input
            }], yMemberAsLegendUnit: [{
                type: Input
            }], yMemberPath: [{
                type: Input
            }], useBruteForce: [{
                type: Input
            }], progressiveLoad: [{
                type: Input
            }], heatMinimum: [{
                type: Input
            }], heatMaximum: [{
                type: Input
            }], heatMinimumColor: [{
                type: Input
            }], heatMaximumColor: [{
                type: Input
            }], pointExtent: [{
                type: Input
            }], progressiveStatus: [{
                type: Input
            }], progressiveLoadStatusChanged: [{
                type: Output
            }] } });
