import { IgrCategoryAxisBase } from "./igr-category-axis-base";
import { ensureBool } from "igniteui-react-core/ES2015/componentUtil";
/**
 * Represents an category-based horizontal X axis that uses a DateTime scale.
*/
export class IgrTimeAxisBase extends IgrCategoryAxisBase {
    constructor(props) {
        super(props);
    }
    get i() {
        return this._implementation;
    }
    /**
     * Gets or sets the DateTime mapping property for the axis.
    */
    get dateTimeMemberPath() {
        return this.i.dateTimeMemberPath;
    }
    set dateTimeMemberPath(v) {
        this.i.dateTimeMemberPath = v;
    }
    /**
     * Gets or sets whether the data assigned to the date time axis should be considered pre-sorted by date/time.
    */
    get isDataPreSorted() {
        return this.i.kv;
    }
    set isDataPreSorted(v) {
        this.i.kv = ensureBool(v);
    }
    /**
     * Gets the coerced minimum value.
    */
    get actualMinimumValue() {
        return this.i.actualMinimumValue;
    }
    set actualMinimumValue(v) {
        this.i.actualMinimumValue = v;
    }
    /**
     * Gets the coerced maximum value.
    */
    get actualMaximumValue() {
        return this.i.actualMaximumValue;
    }
    set actualMaximumValue(v) {
        this.i.actualMaximumValue = v;
    }
    /**
     * Gets or sets the axis MinimumValue.
    */
    get minimumValue() {
        return this.i.minimumValue;
    }
    set minimumValue(v) {
        this.i.minimumValue = v;
    }
    /**
     * Gets or sets the axis MaximumValue.
    */
    get maximumValue() {
        return this.i.maximumValue;
    }
    set maximumValue(v) {
        this.i.maximumValue = v;
    }
    /**
     * Checks if the axis is of date time axis type
    */
    get isDateTime() {
        return this.i.b5;
    }
    /**
     * Checks if axis requires sorting of items
    */
    get isSorting() {
        return this.i.cc;
    }
    /**
     * Gets the index of the data item with the value nearest the given value.
    
    * @param unscaledValue  * The value to find a value close to.
    */
    getIndexClosestToUnscaledValue(unscaledValue) {
        let iv = this.i.i$f(unscaledValue);
        return (iv);
    }
    /**
     * Updates the axis when the data has been changed.
    
    */
    notifyDataChanged() {
        this.i.i$i();
    }
}
