import { HighlightingState_$type } from "./HighlightingState";
import { HighlightingInfo as HighlightingInfo_internal } from "./HighlightingInfo";
import { ensureEnum, ensureBool } from "igniteui-react-core/ES5/componentUtil";
/**
 * Contains contextual information about a highlighting.
*/
var HighlightingInfo = /** @class */ (function () {
    function HighlightingInfo() {
        this._implementation = this.createImplementation();
        this._implementation.externalObject = this;
        this.onImplementationCreated();
    }
    HighlightingInfo.prototype.createImplementation = function () {
        return new HighlightingInfo_internal();
    };
    Object.defineProperty(HighlightingInfo.prototype, "i", {
        get: function () {
            return this._implementation;
        },
        enumerable: true,
        configurable: true
    });
    HighlightingInfo.prototype.onImplementationCreated = function () {
    };
    HighlightingInfo.prototype._provideImplementation = function (i) {
        this._implementation = i;
        this._implementation.externalObject = this;
        this.onImplementationCreated();
    };
    Object.defineProperty(HighlightingInfo.prototype, "startIndex", {
        /**
         * The index of the first highlighted item.
        */
        get: function () {
            return this.i.f;
        },
        set: function (v) {
            this.i.f = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(HighlightingInfo.prototype, "endIndex", {
        /**
         * The index of the last highlighted item.
        */
        get: function () {
            return this.i.e;
        },
        set: function (v) {
            this.i.e = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(HighlightingInfo.prototype, "state", {
        /**
         * The state of the highlighting.
        */
        get: function () {
            return this.i.a;
        },
        set: function (v) {
            this.i.a = ensureEnum(HighlightingState_$type, v);
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(HighlightingInfo.prototype, "progress", {
        /**
         * A number between 0 and 1 representing the progress of the highlighting.
        */
        get: function () {
            return this.i.d;
        },
        set: function (v) {
            this.i.d = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(HighlightingInfo.prototype, "isMarker", {
        /**
         * True if this HighlightingInfo represents a marker highlighting.
        */
        get: function () {
            return this.i.c;
        },
        set: function (v) {
            this.i.c = ensureBool(v);
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(HighlightingInfo.prototype, "series", {
        /**
         * The series in context.
        */
        get: function () {
            if (this.i.b == null) {
                return null;
            }
            return this.i.b.externalObject;
        },
        enumerable: true,
        configurable: true
    });
    return HighlightingInfo;
}());
export { HighlightingInfo };
