import type { CacheNodeSeedData, FlightRouterState } from '../../../server/app-render/types';
import type { CacheNode, HeadData, ReadyCacheNode } from '../../../shared/lib/app-router-context.shared-runtime';
import type { FetchServerResponseResult } from './fetch-server-response';
export type Task = {
    route: FlightRouterState;
    node: CacheNode | null;
    dynamicRequestTree: FlightRouterState | null;
    children: Map<string, Task> | null;
};
export declare function updateCacheNodeOnNavigation(oldCacheNode: CacheNode, oldRouterState: FlightRouterState, newRouterState: FlightRouterState, prefetchData: CacheNodeSeedData | null, prefetchHead: HeadData | null, isPrefetchHeadPartial: boolean): Task | null;
export declare function listenForDynamicRequest(task: Task, responsePromise: Promise<FetchServerResponseResult>): void;
export declare function abortTask(task: Task, error: any): void;
export declare function updateCacheNodeOnPopstateRestoration(oldCacheNode: CacheNode, routerState: FlightRouterState): ReadyCacheNode;
