/// <reference types="react" />
import { ViewController } from './ctr';
import * as _history from 'history';
import { Location } from 'history';
import { Router } from './router';
import { match } from 'react-router';
export declare type History = _history.History;
export interface PageProps {
    router: Router;
    history: History;
    location: Location;
    match: match;
}
export default class Page<P = {}, S = {}> extends ViewController<PageProps & P, S> {
    private _url;
    private _params;
    private _router?;
    constructor(props: P & PageProps);
    get url(): string;
    get pathname(): string;
    get history(): History;
    get location(): _history.Location<unknown>;
    get match(): match<{}>;
    get params(): P;
    protected triggerLoad(): void;
    protected triggerRemove(): void;
    goBack(): void;
    goForward(): void;
    goto(args: string | {
        url: string;
        params?: Dict;
    }): void;
}
export declare class Loading extends Page<{
    content?: string;
}, {}> {
    render(): JSX.Element;
}
export interface IDataPage<Data> {
    name: string;
    dataPage: number;
    readonly dataPageCount: number;
    data: Data[];
    readonly indexPage: number;
    index: number;
    total: number;
    readonly length: number;
    readonly hasMore: boolean;
    loadMore(): Promise<void>;
    reload(params: Dict, page?: number): Promise<void>;
    loadData(params: Dict): Promise<{
        value: Data[];
        total?: number;
        index?: number;
    }>;
}
export declare class DataPage<P = {}, S = {}, Data = Dict> extends Page<P, S> implements IDataPage<Data> {
    private m_name?;
    private m_dataPage?;
    private m_index?;
    private m_total?;
    private m_load_data_params?;
    static setDefaultDataPage(page: number): void;
    get name(): string;
    set name(value: string);
    get dataPage(): number;
    set dataPage(value: number);
    get dataPageCount(): number;
    get data(): Data[];
    set data(value: Data[]);
    get indexPage(): number;
    get index(): number;
    set index(value: number);
    get total(): number;
    set total(value: number);
    get length(): number;
    get hasMore(): boolean;
    loadMore(): Promise<void>;
    reload(params?: Dict, page?: number): Promise<void>;
    loadData(params: Dict): Promise<{
        value: Data[];
        total?: number;
        index?: number;
    }>;
}
