/// <reference types="node" />
/**
 * Copyright (c) OpenLens Maintainers. All rights reserved.
 * Licensed under MIT License. See LICENSE in root directory for more information.
 */
import type { GetPortFromStream } from "../../../utils/get-port-from-stream.injectable";
import type { ChildProcessWithoutNullStreams } from "child_process";
import type { Logger } from "@openlens/logger";
export interface PortForwardArgs {
    clusterId: string;
    kind: string;
    namespace: string;
    name: string;
    port: number;
    forwardPort: number;
}
export interface PortForwardDependencies {
    readonly logger: Logger;
    getKubectlBinPath: (bundled: boolean) => Promise<string>;
    getPortFromStream: GetPortFromStream;
}
export declare class PortForward {
    private dependencies;
    pathToKubeConfig: string;
    static portForwards: PortForward[];
    static getPortforward(forward: PortForwardArgs): PortForward | undefined;
    process?: ChildProcessWithoutNullStreams;
    clusterId: string;
    kind: string;
    namespace: string;
    name: string;
    port: number;
    forwardPort: number;
    constructor(dependencies: PortForwardDependencies, pathToKubeConfig: string, args: PortForwardArgs);
    start(): Promise<boolean>;
    stop(): Promise<void>;
}
