import { IDatasource, IGetRowsParams, IServerSideDatasource, IServerSideGetRowsParams, ColumnVO } from "ag-grid-community";
import { IRequestObject } from './repository';
import * as breeze from 'breeze-client';
import { AgGridToBreezeTransformer } from "./service-base";
import { GridOptions } from "./../resources/elements/utilities/ag-grid-helpers";
export interface IGetPredicatesFunc {
    (filterText: string): breeze.Predicate;
}
export interface IGetDataFunc {
    (requestObj: IRequestObject): Promise<{
        results: any;
        fullCount?: number;
        error?: any;
    }>;
}
export interface IGetGroupDataFunc {
    (valueCols: ColumnVO[], groupKeys: string[], requestObj: IRequestObject): Promise<{
        results: any;
        fullCount?: number;
        error?: any;
    }>;
}
export interface IBeforeFetchingFunc {
    (requestObj: IRequestObject): Promise<any>;
}
export interface IAgGridDataSource extends IDatasource {
    filterText: string;
    expands: string[];
    queryParameters: any;
    getRows(params: any): any;
    beforeFetching(requestObj: IRequestObject): IRequestObject;
}
export declare abstract class BaseGridDataSource implements IAgGridDataSource {
    private resourceName;
    predicates: breeze.Predicate;
    getPredicatesFunction: IGetPredicatesFunc;
    getDataFunction: IGetDataFunc;
    filterText: string;
    expands: string[];
    queryParameters: any;
    constructor(resourceName: string);
    getTransformer(): AgGridToBreezeTransformer;
    getRows(params: any): void;
    beforeFetching(requestObj: IRequestObject): IRequestObject;
}
export declare class GridDataSource extends BaseGridDataSource {
    getRows(params: IGetRowsParams): Promise<{
        results: any;
        fullCount?: number;
        error?: any;
    }>;
}
export declare class ServerSideDataSource extends BaseGridDataSource implements IServerSideDatasource {
    private gridOptions;
    private expandedGroupIds;
    setGridOptions(gridOptions: GridOptions): void;
    getGroupDataFunction: IGetGroupDataFunc;
    getRows(params: IServerSideGetRowsParams): Promise<void>;
}
