import { WeavyClient } from './weavy';
import { RealtimeDataType, RealtimeEventType } from '../types/realtime.types';
import { HubConnection } from '../../@microsoft/signalr/dist/browser/signalr.min.js';
import { Constructor } from '../types/generic.types';
export interface WeavyConnectionProps {
    whenConnectionRequested: () => Promise<void>;
    whenConnectionStarted: () => Promise<HubConnection>;
    whenConnectionCreated: () => Promise<HubConnection>;
    createConnection: () => Promise<HubConnection>;
    disconnect: () => Promise<void>;
    connect: () => Promise<HubConnection>;
    subscribe: <T extends RealtimeEventType | RealtimeDataType>(group: string | null, event: string, callback: (realTimeEvent: T) => void | Promise<void>) => Promise<boolean>;
    unsubscribe: <T extends RealtimeEventType | RealtimeDataType>(group: string | null, event: string, callback: (realTimeEvent: T) => void) => Promise<void>;
}
export declare const WeavyConnectionMixin: <TBase extends Constructor<WeavyClient>>(Base: TBase) => {
    new (...args: any[]): {
        _resolveConnectionRequested?: (value: unknown) => void;
        _whenConnectionRequested: Promise<unknown>;
        whenConnectionRequested(): Promise<void>;
        _resolveConnectionCreated?: (value: HubConnection) => void;
        _whenConnectionCreated: Promise<HubConnection>;
        whenConnectionCreated(): Promise<HubConnection>;
        _connection?: HubConnection;
        _connectionEventListeners: Array<{
            name: string;
            callback: (realtimeEvent: never) => void;
        }>;
        signalRAccessTokenRefresh: boolean;
        _whenConnectionStartedResolve?: (value: HubConnection) => void;
        _whenConnectionStartedReject?: (reason: unknown) => void;
        _whenConnectionStarted: Promise<HubConnection>;
        readonly rtmConnection: HubConnection | undefined;
        whenConnectionStarted(): Promise<HubConnection>;
        createConnection(this: /*elided*/ any & WeavyClient & import('./weavy').StrictWeavyOptions & import('./settings').WeavySettingsProps & import('./network').WeavyNetworkProps & import('./authentication').WeavyAuthenticationProps & import('./localization').WeavyLocalizationProps & WeavyConnectionProps & import('./query').WeavyQueryProps & import('./version').WeavyVersionProps & import('./fetch').WeavyFetchProps & import('./styles').WeavyStylesProps & import('./realtime').WeavyRealtimeProps & import('./api').WeavyApiProps & import('./context').WeavyContextProviderProps): Promise<HubConnection>;
        disconnect(this: /*elided*/ any & WeavyClient & import('./weavy').StrictWeavyOptions & import('./settings').WeavySettingsProps & import('./network').WeavyNetworkProps & import('./authentication').WeavyAuthenticationProps & import('./localization').WeavyLocalizationProps & WeavyConnectionProps & import('./query').WeavyQueryProps & import('./version').WeavyVersionProps & import('./fetch').WeavyFetchProps & import('./styles').WeavyStylesProps & import('./realtime').WeavyRealtimeProps & import('./api').WeavyApiProps & import('./context').WeavyContextProviderProps): Promise<void>;
        connect(this: /*elided*/ any & WeavyClient & import('./weavy').StrictWeavyOptions & import('./settings').WeavySettingsProps & import('./network').WeavyNetworkProps & import('./authentication').WeavyAuthenticationProps & import('./localization').WeavyLocalizationProps & WeavyConnectionProps & import('./query').WeavyQueryProps & import('./version').WeavyVersionProps & import('./fetch').WeavyFetchProps & import('./styles').WeavyStylesProps & import('./realtime').WeavyRealtimeProps & import('./api').WeavyApiProps & import('./context').WeavyContextProviderProps): Promise<HubConnection>;
        subscribe<T extends RealtimeEventType | RealtimeDataType>(group: string | null, event: string, callback: (realtimeEvent: T) => void): Promise<boolean>;
        unsubscribe<T extends RealtimeEventType | RealtimeDataType>(group: string | null, event: string, callback: (realTimeEvent: T) => void): Promise<void>;
        destroy(this: /*elided*/ any & WeavyClient & import('./weavy').StrictWeavyOptions & import('./settings').WeavySettingsProps & import('./network').WeavyNetworkProps & import('./authentication').WeavyAuthenticationProps & import('./localization').WeavyLocalizationProps & WeavyConnectionProps & import('./query').WeavyQueryProps & import('./version').WeavyVersionProps & import('./fetch').WeavyFetchProps & import('./styles').WeavyStylesProps & import('./realtime').WeavyRealtimeProps & import('./api').WeavyApiProps & import('./context').WeavyContextProviderProps): void;
        readonly weavySid: string;
        readonly weavyId: string;
        readonly host: HTMLElement;
        cloudFilePickerUrl: string | URL;
        disableEnvironmentImports: boolean;
        gcTime: number;
        scrollBehavior: "smooth" | "instant" | "auto";
        staleTime: number;
        tokenFactoryRetryDelay: number;
        tokenFactoryTimeout: number;
        "__#16@#resolveUrl"?: (url: URL) => void;
        "__#16@#whenUrl": Promise<unknown>;
        whenUrl(): Promise<void>;
        "__#16@#url"?: URL;
        get url(): URL | undefined;
        set url(url: string | URL | null | undefined);
        readonly cachePrefix: string;
        reset(): Promise<void>;
        "__#16@#isDestroyed": boolean;
        readonly isDestroyed: boolean;
    };
} & TBase;
//# sourceMappingURL=connection.d.ts.map