import { OnDestroy } from '@angular/core';
import { BehaviorSubject, Observable, Subscription } from 'rxjs';
import { CursorPaginationApiCall } from '@armor/api';
import { AbstractServerDataService } from './abstract-server-data.service';
import { DataTableConfig } from '../../models/tables/data-table-config';
/**
 * This data service can be used against an API that returns a paged list using the cursor pagination strategy
 * described by CursorPaginationApiCall. See src/stories/pagination.stories.ts for an example implementation.
 *
 */
export declare class CursorPaginationDataService<TModel> extends AbstractServerDataService<TModel> implements OnDestroy {
    constructor();
    apiCall: CursorPaginationApiCall<TModel>;
    defaultPageSize: number;
    cursors: any;
    data: BehaviorSubject<TModel[]>;
    dataTableConfig: DataTableConfig;
    isLoading: boolean;
    paginationChangeSubscription: Subscription;
    ngOnDestroy(): void;
    /**
     * This is the main method that drives the data service. It serves as a bridge between
     * the API layer and the table UI.
     * - get the data via the supplied apiCall
     * - update this.data, which is used directly by te table
     * - update the paging state with the paging data returned by the API
     * - update the isLoading state
     */
    getData(pageSize?: number, pageDirection?: 'next' | 'previous'): Promise<TModel[]>;
    /**
     * isLoading is used by the table to show the loading indicator
     */
    setLoadingState(newValue: boolean): void;
    /**
     * This updated this.data, which is consumed directly by the table using the async pipe
     */
    setData(data: TModel[]): void;
    /**
     * Update the paging state so that it can be used by the next paging event
     */
    setPagingState(paging: any): void;
    hasNext: () => boolean;
    hasPrev: () => boolean;
    getAllData(): Observable<TModel[]>;
    processData(): Observable<any[]>;
}
