import Ext from "../../../tr-grid-util/es6/Ext.js"; import DataCache from "./DataCache.js"; import Util from "../grid/util/util.js"; import Segment from "./Segment.js"; // eslint-disable-line import SegmentCollection from "./SegmentCollection.js"; declare namespace DataTable { type SortLogic = ((...params: any[]) => any)|null; } declare class DataTable extends DataCache { constructor(); public getRowId(rowIndex: number): string; public getRowIndex(rid: string): number; public getRowCount(): number; public getDataAt(rowIndex: number, cid: string): { [key: string]: any }; public getRowDataAt(rowIndex: number): { [key: string]: any }; public getPreviousData(rid: string, cid: string): { [key: string]: any }; public setRowData(rid: string, values?: { [key: string]: any }|null, eventArg?: any): boolean; public setColumnData(cid: string, valueList: (any)[], opt_ridList?: (string)[]|null): void; public setDataFromObjectMap(obj: { [key: string]: any }): void; public setDataFrom2DArray(ary: (any)[][], opt_cidList?: (string)[]|null, opt_ridList?: (string)[]|null): void; public setDataAt(rowIndex: number, cid: string, value: any): boolean; public setRowDataAt(rowIndex: number, values?: { [key: string]: any }|null, opt_eventArg?: any): boolean; public addRow(values?: { [key: string]: any }|null, rid?: string|null|null): string; public addRows(rows: (any)[]|null, rids?: (string)[]|null): void; public unshiftRow(opt_values?: { [key: string]: any }|null, opt_rid?: string|null|null): string; public insertRow(rowRef?: (string|number|null)|null, values?: { [key: string]: any }|null, rid?: string|null|null): string; public insertAfter(rowRef: string|number|null, opt_values?: any, opt_rid?: string|null): string; public removeRow(rowRef: number|string|null): void; public removeRows(refs: (number|string)[]|null): void; public removeAllRows(suppressEvent?: boolean|null): void; public moveRow(fromIndex: (number)[]|number|null, toIndex: number, suppressEvent?: boolean|null): (string)[]|string|null; public moveRows(startIndex: number|string|null, toIndex: number|string|null, opt_count?: number|null, suppressEvent?: boolean|null): (string)[]|null; public swapRow(fromIndex: number, toIndex: number): void; public clearRowData(rid: string): void; public getDataSource(): null; public setDataSource(source: any): void; public sortOnce(cid: string|(string)[]|null, sortOrders?: (string|number|(string|number)[])|null, customComparer?: DataTable.SortLogic|null, contextObj?: any): boolean; public setSortingLogic(func: DataTable.SortLogic|null): void; public setColumnSortingLogic(cid: string, func: DataTable.SortLogic|null): void; public getColumnSortingLogic(cid?: string|null): DataTable.SortLogic|null; public freeze(bool?: boolean|null): boolean; public unfreeze(bool?: boolean|null): boolean; public isFrozen(): boolean; public setSegmentSeparators(rids: (string)[]|null, enabled?: boolean|null): boolean; public setSegmentSeparator(rid: string, options?: any): boolean; public unsetAllSegmentSeparators(): boolean; public hasSegmentation(): boolean; public hasSegmentClassification(): boolean; public isSegmentSeparator(rid: string): boolean; public getSegment(rid: string): Segment|null; public getSegmentParent(rid: string): Segment|null; public getSegmentLevel(rid: string): number; public getSegmentParentRowId(rid: string): string; public getSegmentValues(rids?: (string)[]|null, partial?: boolean|null): (number)[]|null; public fillSegment(segmentId: string): void; public fillSegments(): boolean; public addSegmentChild(segmentId: string, rid: string, dataId?: string|null): boolean; public addSegmentChildren(segmentId: string, rids: (string)[]|null, dataIds?: (string)[]|null): boolean; public setSegmentChildren(segmentArr: (any)[]|null): boolean; public removeSegmentChild(segmentId: string, rid: string): boolean; public removeSegmentChildren(segmentId: string, rids: (string)[]|null): boolean; public removeAllSegmentChildren(): boolean; public getSegmentIds(): (string)[]|null; public getSegmentChildIds(segmentId: string): (string)[]|null; public sortSeparators(sortLogics: ((...params: any[]) => any)|(((...params: any[]) => any))[]|any|null, sortOrders?: (number|string)[]|null, cids?: (string)[]|null): boolean; public sortSegments(compare: ((...params: any[]) => any)|null): boolean; public setClassificationSource(dc: DataCache|null): void; public setSegmentClassification(segmentId: string, fields: string|(string)[]|null): boolean; public classifySegments(): boolean; public requestClassifying(): void; public setSegmentDefaultCollapsing(bool: boolean): boolean; public dispatchGlobalChange(suppressEvent?: boolean|null): void; public static getSortingDefinitions(): void; } declare function rowIndex(cid: string, valueList: (any)[], opt_ridList?: (string)[]|null): void; declare function prevFrozen(ary: (any)[][], opt_cidList?: (string)[]|null, opt_ridList?: (string)[]|null): void; declare function cid(): null; declare function removalList(bool: boolean): boolean; declare function logic(a: number, b: number, order: number, sortingDefs: (any[])[]|null): number; export default DataTable; export { DataTable };