import { ComputedQuery, DataResultRaw, FiltersMap, OptionalFiltersMap } from '../model';
export type OffsetQuery<F extends FiltersMap = OptionalFiltersMap> = Omit<ComputedQuery<F>, 'cursor'>;
export type OffsetQueryResult<T> = Omit<DataResultRaw<T>, 'cursor'>;
export type OffsetFetchDataFn<T, F extends FiltersMap> = (query: OffsetQuery<F>) => Promise<OffsetQueryResult<T>>;
export type CursorQueryResult<T> = Omit<DataResultRaw<T>, 'cursor'> & {
    cursor: string | undefined | null;
};
export type CursorQuery<F extends FiltersMap = OptionalFiltersMap> = Omit<ComputedQuery<F>, 'offset'>;
export type CursorFetchDataFn<T, F extends FiltersMap> = (query: CursorQuery<F>) => Promise<CursorQueryResult<T>>;
export type FetchTotalFn = (query: CursorQuery) => Promise<number>;
export type PaginationModeConfig<T, F extends FiltersMap> = {
    paginationMode?: 'offset';
    fetchData: OffsetFetchDataFn<T, F>;
} | {
    paginationMode: 'cursor';
    fetchTotal?: FetchTotalFn;
    fetchData: CursorFetchDataFn<T, F>;
};
//# sourceMappingURL=paginationModeConfig.d.ts.map