import { VegaSlimmer } from '../../../../vega-slimmer/vega-slimmer-core';
import { VegaTableDataSourceItem, VegaTableRowSelectionConfig } from '../../interface';
import { VegaTable } from '../../vega-table';
import { Nullable } from '../../../../types/general';
/**
 *
 */
export declare class VegaTableRowSelectionController extends VegaSlimmer {
  host: VegaTable['host'];
  isSelectedAll: VegaTable['isSelectedAll'];
  selectedRowKeySet: VegaTable['selectedRowKeySet'];
  rowSelection: VegaTable['rowSelection'];
  rowKey: VegaTable['rowKey'];
  selectChangeEventEmitter: VegaTable['selectChangeEventEmitter'];
  selectAllChangeEventEmitter: VegaTable['selectAllChangeEventEmitter'];
  vegaTableDataSourceController: VegaTable['vegaTableDataSourceController'];
  rowSelectEventEmitter: VegaTable['rowSelectEventEmitter'];
  rowSelectAllEventEmitter: VegaTable['rowSelectAllEventEmitter'];
  private rowSelectionObserver;
  private rowSelectionAllObserver;
  private rowClickObserver;
  /**
   * Component lifecycle - connectedCallback
   */
  connectedCallback(): void;
  /**
   *
   */
  disconnectedCallback(): void;
  /**
   * Component lifecycle - componentWillLoad
   */
  componentWillLoad(): void;
  /**
   * The callback to handle [watchRowSelection]{@link VegaTable.watchRowSelection}
   *
   * @param {VegaTableRowSelectionConfig} newValue - The changed value of rowSelection
   * @param {VegaTableRowSelectionConfig} oldValue - The value of rowSelection before changing
   */
  watchRowSelection(newValue: VegaTableRowSelectionConfig, oldValue: VegaTableRowSelectionConfig): void;
  /**
   * The callback to handle [setSelection]{@link VegaTable.setSelection}
   *
   * @param {string[]} keys - The keys array of which you want to select
   */
  setSelection(keys: string[]): void;
  /**
   * The callback to handle [watchCurrentData]{@link VegaTable.watchCurrentData}
   *
   * @param {VegaTableDataSourceItem} currentData - The changed value of currentData
   */
  watchCurrentData(currentData: VegaTableDataSourceItem[]): void;
  /**
   * The callback to handle [clearSelection]{@link VegaTable.clearSelection}
   */
  clearSelection(): void;
  /**
   * The callback to handle [getSelection]{@link VegaTable.getSelection}
   *
   * @returns {string[]} The selected row keys array
   */
  getSelection(): string[];
  /**
   *
   */
  watchSelectedRowKeySet(): void;
  /**
   *
   */
  watchSelectedAll(): void;
  /**
   * The method for handling row selection change
   *
   * @param {boolean} checked - true: the row is selected, otherwise not selected
   * @param {VegaTableDataSourceItem} record - The record of the changed row
   */
  handleRowSelect: (checked: boolean, record: VegaTableDataSourceItem) => void;
  /**
   * Get the row selection type
   *
   * @returns {Nullable<'multiple' | 'single'>} Return the type of the row selection
   */
  getRowSelectionType: () => Nullable<'multiple' | 'single'>;
  /**
   * The method for handing the single row selection
   *
   * @param {VegaTableDataSourceItem} record - The record of the single selected row
   */
  handleSingleRowSelect: (record: VegaTableDataSourceItem) => void;
  /**
   * Verify the row is checked or not for row selection
   *
   * @param {string} key - The row key of the row
   * @returns {boolean} Return true if the row is selected, otherwise false
   */
  isChecked: (key: string) => boolean;
  /**
   * The method to handling select all rows
   *
   * @param {boolean} checkedAll - true: all rows are selected; false: not selected all rows
   */
  handleSelectAll: (checkedAll: boolean) => void;
  /**
   * Verify if all rows are selected
   *
   * @returns {boolean} return true if all rows are selected, otherwise false
   */
  isCheckedAll: () => boolean;
  /**
   * Set up the row selection config
   *
   * @param {VegaTableRowSelectionConfig} config - The config of the row selection
   */
  private setupRowSelection;
  /**
   * Get the selected rows records array
   *
   * @returns {VegaTableDataSourceItem[]} The array of the all selected row's records
   */
  private getSelectedRecords;
  /**
   * Sync up the selected row's key when current data changed
   *
   * @param {VegaTableDataSourceItem[]} currentData - The current data of the source
   */
  private syncUpSelectedKeySetWithCurrentData;
  /**
   * The function checks if the input is an acceptable table row observer by verifying its host tag name and ensuring it is a child of a vega-table element.
   *
   * @param {unknown} input - The `input` parameter is of type `unknown`, which means it can be any type.
   * @returns {boolean} boolean value indicating whether the input is of type T and satisfies certain conditions.
   */
  private isAcceptableRowSelectionObserver;
  /**
   * The function checks if the input is an acceptable observer for a table head row in a Vega table.
   *
   * @param {unknown} input - The `input` parameter is of type `unknown`, which means it can be any type.
   * @returns {boolean}  boolean value.
   */
  private isAcceptableRowSelectionAllObserver;
  /**
   * The function initializes a row selection.
   */
  private initRowSelection;
  /**
   * The function initializes an observer for row selection all in a table
   */
  private initRowSelectionAllObserver;
  /**
   * The function initializes a row click observer that handles row selection in a table.
   */
  private initRowClickObserver;
  /**
   * The function checks if the input is an acceptable row click observer.
   *
   * @param {unknown} input - The input parameter is of type unknown, which means it can be any type.
   * @returns {boolean} a boolean value indicating whether the input is acceptable observer.
   */
  private isAcceptableRowClickObserver;
}
