import { Cache, StateCallback, StateEvents, StateObject, StatePropCallback } from "@hpcc-js/util";
import { IConnection, IOptions } from "../connection.ts";
import { TopologyService, WsTopology } from "../services/wsTopology.ts";
import { TargetCluster } from "./targetCluster.ts";
export declare class TopologyCache extends Cache<{
    BaseUrl: string;
}, Topology> {
    constructor();
}
export interface TopologyStateEx {
    TargetClusters?: WsTopology.TpTargetCluster[];
    LogicalClusters?: WsTopology.TpLogicalCluster[];
    Services?: WsTopology.ServiceList;
}
export declare class Topology extends StateObject<TopologyStateEx, TopologyStateEx> implements TopologyStateEx {
    protected connection: TopologyService;
    get BaseUrl(): string;
    get properties(): TopologyStateEx;
    get TargetClusters(): WsTopology.TpTargetCluster[];
    get CTargetClusters(): TargetCluster[];
    get LogicalClusters(): WsTopology.TpLogicalCluster[];
    get Services(): WsTopology.ServiceList;
    static attach(optsConnection: IOptions | IConnection | TopologyService, state?: TopologyStateEx): Topology;
    protected constructor(optsConnection: IOptions | IConnection | TopologyService);
    GetESPServiceBaseURL(type?: string): Promise<string>;
    fetchTargetClusters(): Promise<TargetCluster[]>;
    fetchLogicalClusters(request?: WsTopology.TpLogicalClusterQueryRequest): Promise<WsTopology.TpLogicalCluster[]>;
    fetchServices(request?: WsTopology.TpServiceQueryRequest): Promise<WsTopology.ServiceList>;
    protected _prevRefresh: any;
    refresh(force?: boolean): Promise<this>;
    on(eventID: StateEvents, propIDorCallback: StateCallback | keyof TopologyStateEx, callback?: StatePropCallback): this;
}
