import { Network } from '../../../protocol/protocol.js';
import type { CdpClient } from '../../BidiMapper.js';
import type { CdpTarget } from '../context/CdpTarget.js';
import type { EventManager } from '../session/EventManager.js';
import { NetworkRequest } from './NetworkRequest.js';
interface NetworkInterception {
    urlPatterns: Network.UrlPattern[];
    phases: Network.AddInterceptParameters['phases'];
}
/** Stores network and intercept maps. */
export declare class NetworkStorage {
    #private;
    constructor(eventManager: EventManager, browserClient: CdpClient);
    onCdpTargetCreated(cdpTarget: CdpTarget): void;
    toggleInterception(): Promise<void>;
    requestBlockedBy(request: NetworkRequest, phase?: Network.InterceptPhase): Set<Network.Intercept>;
    disposeRequestMap(sessionId: string): void;
    /**
     * Adds the given entry to the intercept map.
     * URL patterns are assumed to be parsed.
     *
     * @return The intercept ID.
     */
    addIntercept(value: NetworkInterception): Promise<Network.Intercept>;
    /**
     * Removes the given intercept from the intercept map.
     * Throws NoSuchInterceptException if the intercept does not exist.
     */
    removeIntercept(intercept: Network.Intercept): Promise<void>;
    getRequestById(id: Network.Request): NetworkRequest | undefined;
    getRequestByFetchId(fetchId: Network.Request): NetworkRequest | undefined;
    addRequest(request: NetworkRequest): void;
    deleteRequest(id: Network.Request): void;
}
export {};
