import { IRow } from '../../../../../../types/src/table';
import { default as Cell } from '../../core/cell/Cell';
import { default as Column } from '../../core/column/Column';
import { default as Module } from '../../core/Module';
import { default as Row } from '../../core/row/Row';
import { ColumnCalcParams, ITabulator } from '../../core/types';

type CalcFunction = (values: any[], data: Array<Record<string, any>>, params: ColumnCalcParams) => any;
export default class ColumnCalcs extends Module {
    static moduleName: string;
    static calculations: Record<string, CalcFunction>;
    topCalcs: Column[];
    botCalcs: Column[];
    genColumn: Column | false;
    topElement: HTMLElement;
    botElement: HTMLElement;
    topRow: IRow | false;
    botRow: IRow | false;
    topInitialized: boolean;
    botInitialized: boolean;
    blocked: boolean;
    recalcAfterBlock: boolean;
    constructor(table: ITabulator);
    createElement(): HTMLElement;
    initialize(): void;
    resizeHolderWidth(): void;
    tableRedraw(force?: boolean): Promise<void>;
    blockRedraw(): void;
    restoreRedraw(): void;
    /**
     * Table Functions
     */
    userRecalc(): Promise<void>;
    /**
     * Internal Logic
     */
    blockCheck(): boolean;
    visibleRows(viewable: any, rows: IRow[]): IRow[];
    rowsUpdated(row?: IRow): void;
    recalcActiveRowsRefresh(): Promise<void>;
    recalcActiveRows(): Promise<void>;
    cellValueChanged(cell: Cell): void;
    initializeColumnCheck(column: Column): void;
    initializeColumn(column: Column): void;
    registerColumnField(): void;
    removeCalcs(): void;
    reinitializeCalcs(): void;
    initializeTopRow(): void;
    initializeBottomRow(): void;
    scrollHorizontal(left: number): void;
    recalc(rows: IRow[]): Promise<void>;
    recalcRowGroup(row: IRow): void;
    recalcAll(): Promise<void>;
    recalcGroup(group: any): void;
    generateTopRow(rows: Row[]): IRow;
    generateBottomRow(rows: Row[]): IRow;
    rowsToData(rows: IRow[]): Array<Record<string, any>>;
    generateRow(pos: 'top' | 'bottom', data: Array<Record<string, any>>): IRow;
    generateRowData(pos: 'top' | 'bottom', data: Array<Record<string, any>>): Record<string, any>;
    hasTopCalcs(): boolean;
    hasBottomCalcs(): boolean;
    redraw(): void;
    getResults(): Record<string, any>;
    getGroupResults(group: any): Record<string, any>;
    adjustForScrollbar(width: number): void;
}
export {};
