import { FocusableOption, FocusMonitor, FocusOrigin } from '@angular/cdk/a11y';
import { DataSource } from '@angular/cdk/collections';
import { FlatTreeControl } from '@angular/cdk/tree';
import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, OnChanges, OnDestroy, SimpleChanges } from '@angular/core';
import { MatPaginator } from '@angular/material/paginator';
import { MatSort, SortDirection } from '@angular/material/sort';
import { MatTreeFlatDataSource } from '@angular/material/tree';
import { NgmAppearance } from '@metad/ocap-angular/core';
import { AggregationRole, DataSettings, Dimension, EntityType, FlatTreeNode, IMember, ISlicer, isNil, Measure, PivotColumn, PrimitiveType, TreeNodeInterface } from '@metad/ocap-core';
import { TranslateService } from '@ngx-translate/core';
import { BehaviorSubject, Observable } from 'rxjs';
import { NgmAnalyticsBusinessService } from './analytics.service';
import { NgmFlatTableDataSource } from './flat-data-source';
import { AnalyticalGridColumn, AnalyticalGridColumnOptions, AnalyticalGridOptions, IColumnSelectionEventArgs, VisualMap } from './types';
import { NgmTreeFlatDataSource } from './tree-flat-data-source';
import * as i0 from "@angular/core";
export declare class AnalyticalGridComponent<T> implements OnChanges, AfterViewInit, OnDestroy, FocusableOption {
    #private;
    private translateService;
    private cdr;
    private _focusMonitor;
    elementRef: ElementRef;
    AggregationRole: typeof AggregationRole;
    C_MEASURES: string;
    isNil: typeof isNil;
    readonly analyticsService: NgmAnalyticsBusinessService<any>;
    private _disabled;
    get disabled(): boolean;
    set disabled(value: any);
    title: string;
    get dataSettings(): DataSettings;
    set dataSettings(value: DataSettings);
    private readonly _dataSettings;
    get options(): AnalyticalGridOptions;
    set options(value: AnalyticalGridOptions);
    private options$;
    appearance: NgmAppearance;
    styling: any;
    readonly columns: import("@angular/core").InputSignal<Record<string, AnalyticalGridColumnOptions>>;
    readonly _columns$: Observable<Record<string, AnalyticalGridColumnOptions>>;
    get slicers(): ISlicer[];
    set slicers(value: ISlicer[]);
    private readonly _slicers;
    columnSelectionChanging: EventEmitter<IColumnSelectionEventArgs>;
    slicersChanging: EventEmitter<ISlicer[]>;
    explain: EventEmitter<any[]>;
    entityTypeChange: EventEmitter<EntityType>;
    set paginator(v: MatPaginator);
    private readonly _paginator;
    sort: MatSort;
    matSortActive: string;
    matSortDirection: SortDirection;
    selected: {
        prevI: number | string;
        prevColumn: number | string;
        i: number | string;
        prevRow?: {
            [key: string]: PrimitiveType;
        };
        rowMembers?: {
            [key: string]: PrimitiveType;
        };
        column: AnalyticalGridColumn;
        columnMembers?: {
            [key: string]: AnalyticalGridColumn;
        };
    };
    virtualScrollItemSize: number;
    flatDataSource: NgmFlatTableDataSource<any>;
    rowRecursiveHierarchy: any;
    readonly rowTreeProperty: import("@angular/core").WritableSignal<string>;
    rowUnfold: boolean;
    columnUnfold: boolean;
    private _data$;
    get dimensionFilters(): {
        [name: string]: string[];
    };
    set dimensionFilters(filters: {
        [name: string]: string[];
    });
    private _dimensionFilters$;
    readonly filteredData$: Observable<any[]>;
    get dataSource(): DataSource<any>;
    treeNodePadding: number;
    /**
     * 行的列配置
     */
    rowAxes: AnalyticalGridColumn[];
    /**
     * First header line of pivot columns
     */
    matHeaders: string[];
    /**
     * Rest header lines of pivot columns
     */
    matRestHeaders: any[];
    columnAxes: any[];
    /**
     * Header columns for body
     */
    matRowColumns: string[];
    /**
     * 列的总行数
     */
    pivotColumnRowCount: number;
    /**
     * 列的列配置
     */
    get pivotColumns(): AnalyticalGridColumn[][];
    set pivotColumns(value: AnalyticalGridColumn[][]);
    private _pivotColumns$;
    private cellColumns$;
    readonly isLoading$: BehaviorSubject<boolean>;
    readonly error$: Observable<any>;
    readonly data$: Observable<any[]>;
    readonly rowAxes$: Observable<AnalyticalGridColumn[]>;
    readonly columnAxes$: Observable<AnalyticalGridColumn[]>;
    private querySchemaColumns;
    readonly querySchemaColumns$: BehaviorSubject<any[]>;
    columnTreeControl: FlatTreeControl<AnalyticalGridColumn, AnalyticalGridColumn>;
    readonly columnsDataSource: MatTreeFlatDataSource<TreeNodeInterface<PivotColumn>, AnalyticalGridColumn, AnalyticalGridColumn>;
    rowTreeControl: FlatTreeControl<FlatTreeNode<T>, FlatTreeNode<T>>;
    readonly rowDataSource: NgmTreeFlatDataSource<TreeNodeInterface<T>, FlatTreeNode<T>, MatPaginator>;
    readonly entityType: import("@angular/core").WritableSignal<EntityType>;
    /**
     * VisualMap for measures
     */
    visualMaps: Record<string, Partial<VisualMap>>;
    /**
    |--------------------------------------------------------------------------
    | Subscriptions (effect)
    |--------------------------------------------------------------------------
    */
    private entityTypeSub;
    private refreshSub;
    private visualMapSub;
    private explainSub;
    private pivotColumnsSub;
    private querySchemaColumnsSub;
    private schemaColumnsSub;
    private _pivotColumnsSub;
    private filteredTreeDataSub;
    private dataSub;
    private filteredFlatDataSub;
    constructor(translateService: TranslateService, cdr: ChangeDetectorRef, _focusMonitor: FocusMonitor, elementRef: ElementRef);
    /** Focuses the button. */
    focus(origin?: FocusOrigin, options?: FocusOptions): void;
    _getHostElement(): any;
    ngOnChanges({ appearance }: SimpleChanges): void;
    ngAfterViewInit(): void;
    refresh(force?: boolean): void;
    /**
     * Merge origin column and column options properties to table column
     *
     * @param column
     * @param columnName
     * @param _columnsOptions
     * @param _columns
     * @returns
     */
    mergeColumnOptions(column: AnalyticalGridColumn, columnName: string, _columnsOptions: Record<string, AnalyticalGridColumnOptions>, _columns?: Array<Dimension | Measure>, entityType?: EntityType): AnalyticalGridColumn;
    characteristicValue(column: AnalyticalGridColumn, data: any[]): AnalyticalGridColumn;
    isRowSelected(row: T, i: number): boolean;
    isRowCell(element: T, column: AnalyticalGridColumn, j: number): boolean;
    selectRow(i: number, row: any): void;
    selectCell(column: AnalyticalGridColumn): void;
    onClickColumnHeader(event: any, column: AnalyticalGridColumn): void;
    toggleColumnTree(column: AnalyticalGridColumn): void;
    toggleRowUnfold(event: any): void;
    toggleColumnUnfold(event: any): void;
    toggleRowTree(event: any, row: any): void;
    onFilterSelectAll(event: any, column: AnalyticalGridColumn, members: IMember[]): void;
    allFiltering(column: AnalyticalGridColumn, members: IMember[]): boolean;
    someFiltering(column: AnalyticalGridColumn, members: IMember[]): boolean;
    onFilterApply(column: AnalyticalGridColumn, members: IMember[]): void;
    moveLeft(name: string): void;
    moveRight(name: string): void;
    onColumnMemberSearch(column: any, text: string): void;
    calcCellClasses(column: AnalyticalGridColumn, row: any): {};
    calcCellStyles(column: AnalyticalGridColumn, row: any): any;
    calcHeatmapColor(column: AnalyticalGridColumn, row: any): any;
    calcBar(column: AnalyticalGridColumn, row: any): {};
    toggleColumnOrder(index: number): void;
    private _columnMembers;
    subscribeColumnMembers(column: any): Observable<IMember[]>;
    subscribeColumnFilteredMembers(column: AnalyticalGridColumn): Observable<IMember[]>;
    downloadData(): Promise<void>;
    treeData: import("@angular/core").Signal<FlatTreeNode<T>[]>;
    flatData: import("@angular/core").Signal<any[]>;
    copy(selected: any): void;
    /**
     * Linked analysis, output selected slicers on table cell
     *
     * @param slicers
     */
    onLinkAnalysis(slicers: ISlicer[]): void;
    unlinkAnalysis(): void;
    getTranslation(keyWord: string, params?: any): string;
    get _isStriped(): boolean;
    get _withToolbar(): boolean;
    keyUpEvent(event: KeyboardEvent): void;
    ngOnDestroy(): void;
    static ɵfac: i0.ɵɵFactoryDeclaration<AnalyticalGridComponent<any>, never>;
    static ɵcmp: i0.ɵɵComponentDeclaration<AnalyticalGridComponent<any>, "ngm-analytical-grid", never, { "title": { "alias": "title"; "required": false; }; "dataSettings": { "alias": "dataSettings"; "required": false; }; "options": { "alias": "options"; "required": false; }; "appearance": { "alias": "appearance"; "required": false; }; "styling": { "alias": "styling"; "required": false; }; "columns": { "alias": "columns"; "required": false; "isSignal": true; }; "slicers": { "alias": "slicers"; "required": false; }; }, { "columnSelectionChanging": "columnSelectionChanging"; "slicersChanging": "slicersChanging"; "explain": "explain"; "entityTypeChange": "entityTypeChange"; }, never, ["*", "[ngmAction]"], false, never>;
}
