import { AdaptableColumn, ColumnFilter, ColumnFilterPredicate, InFilterValue, InFilterValueInfo } from '../types';
import { AdaptablePredicateDef, ColumnFilterDef } from '../AdaptableState/Common/AdaptablePredicate';
/**
 * Provides run-time access to Filter section of Adaptable State.
 */
export interface ColumnFilterApi {
    /**
     * Gets all Filter Predicates available for a given Column
     * @param column Column to lookup
     */
    getFilterPredicateDefsForColumn(column: AdaptableColumn): AdaptablePredicateDef[];
    /**
     * Gets all Filter Predicates available for a given ColumnId
     * @param columnId Id of Column to lookup
     */
    getFilterPredicateDefsForColumnId(columnId: string): AdaptablePredicateDef[] | undefined;
    /**
     * Makes Quick Filter Bar appear
     */
    showQuickFilterBar(): void;
    /**
     * Hides Quick Filter bar
     */
    hideQuickFilterBar(): void;
    /**
     * Whether Quick Filter is available for use
     */
    isQuickFilterAvailable(): boolean;
    /**
     * Whether Quick Filter Form is currently visible
     */
    isQuickFilterVisible(): boolean;
    /**
     * Retrieves all Column Filters in currently applied Layout
     * @returns column filters
     */
    getColumnFilters(): ColumnFilter[];
    /**
     * Retrieves all active/no-suspended Column Filters in currently applied Layout
     * @returns column filters
     */
    getActiveColumnFilters(): ColumnFilter[];
    /**
     * Retrieves the Column Filter for the specified Column.
     * @param columnId Column ID to lookup
     */
    getColumnFilterForColumn(columnId: string): ColumnFilter | undefined;
    /**
     * Retrieves all Column Filters in a given Layout
     * @param layoutName Layout to retrieve Column Filters for
     */
    getColumnFiltersForLayout(layoutName: string): ColumnFilter[];
    /**
     * Sets Column Filters in current Layout; replaces filters for existing column, leaving other column filters in place
     * @param columnFilters Column Filters to set
     * @returns column filters
     */
    setColumnFilters(columnFilters: ColumnFilter[]): ColumnFilter[] | null;
    /**
     * Clears given Column Filter in the current Layout
     * @param columnFilter Column Filter to clear
     */
    clearColumnFilter(columnFilter: ColumnFilter): void;
    /**
     * Clears Column Filter for given Column
     * @param columnId Column for which Column Filter should be cleared
     */
    clearColumnFilterForColumn(columnId: string): void;
    /**
     * Clears Column Filters for given set of Columns
     * @param columns Columns for which Column Filter should be cleared
     */
    clearColumnFiltersForColumns(columns: string[]): void;
    /**
     * Clears all Column Filters in the Current Layout
     */
    clearColumnFilters(): void;
    /**
     * Clears existing Column Filters and sets new ones
     * @param columnFilters Column Filters to set
     */
    clearAndSetColumnFilters(columnFilters: ColumnFilter[]): void;
    /**
     * Checks if a Column Filter is active (i.e. Predicate has no inputs or has inputs with values)
     */
    isColumnFilterActive(columnFilter: ColumnFilter): boolean;
    /**
     * Checks if the given Coumn has an active Column Filter
     * @param columnId Column ID to check
     */
    isColumnFilterActiveForColumn(columnId: string): boolean;
    /**
     * Retrieves the Column Filter definitions for all available Column Filters
     */
    getColumnFilterDefs(): ColumnFilterDef[];
    /**
     * Suspends a Column Filter
     * @param columnFilter Column Filter to Suspend
     */
    suspendColumnFilter(columnFilter: ColumnFilter): void;
    /**
     * Unsuspend a Column Filter
     * @param columnFilter Column Filter to UnSuspend
     */
    unSuspendColumnFilter(columnFilter: ColumnFilter): void;
    /**
     * Suspends all Column Filters
     */
    suspendAllColumnFilters(): void;
    /**
     * Unsuspend all Column Filters
     */
    unSuspendAllColumnFilters(): void;
    /**
     * Retrieves description of given Column Filter
     * @param columnFilter Column Filter to use
     */
    columnFilterToString(columnFilter: ColumnFilter): string;
    /**
     * Retrieves descriptions of given Column Filters
     * @param columnFilters Column Filters to use
     */
    columnFiltersToString(columnFilters: ColumnFilter[]): string;
    /**
     * Sets the Column Filter for a given Column (clears any existing)
     * @param columnId - Column ID to set Column Filter for
     * @param predicate - Column Filter to set
     */
    setColumnFilterForColumn(columnId: string, predicate: ColumnFilterPredicate): void;
    /**
     * Adds the Blanks Predicate if any value is null, undefined or an empty string
     * @param columnDistinctValues list to check for empty values
     */
    addBlanksToInFilterValues(columnDistinctValues: InFilterValueInfo[]): InFilterValueInfo[];
    /**
     * Refresh(reload) the filter values for a given Column (for `IN` Filter).
     *
     * @param columnId - the ID of the Column for which to refresh filter values.
     * @return a Promise that resolves to the list of filter values, each represented as an object with `value` and `label` properties.
     */
    refreshFilterValues(columnId: string): Promise<InFilterValue[]>;
    /**
     * Refreshes (reloads) the filter values for ALL Columns (for `IN` Filter).
     *
     * @returns A Promise that resolves to a map where:
     *          - keys are column IDs (string)
     *          - values are arrays of filter values for the corresponding column
     *            Each filter value contains a `value` and display `label` property
     */
    refreshAllFilterValues(): Promise<Record<string, InFilterValue[]>>;
    /**
     * Reset(clear cache) the filter values for a given Column (for `IN` Filter).
     * @param columnId - the ID of the Column for which to reset filter values.
     */
    resetFilterValues(columnId: string): void;
    /**
     * Reset(clear cache) the filter values for ALL Columns (for `IN` Filter).
     */
    resetAllFilterValues(): void;
}
