import type { IDoctorCheck, AppiumLogger, DoctorCheckResult } from '@appium/types';
import '@colors/colors';
export declare class OptionalSimulatorCheck implements IDoctorCheck {
    static readonly SUPPORTED_SIMULATOR_PLATFORMS: SimulatorPlatform[];
    log: AppiumLogger;
    diagnose(): Promise<DoctorCheckResult>;
    fix(): Promise<string>;
    hasAutofix(): boolean;
    isOptional(): boolean;
    private _listInstalledSdks;
}
export declare const optionalSimulatorCheck: OptionalSimulatorCheck;
export declare class OptionalApplesimutilsCommandCheck implements IDoctorCheck {
    static readonly README_LINK = "https://github.com/appium/appium-xcuitest-driver/blob/master/docs/reference/execute-methods.md#mobile-setpermission";
    log: AppiumLogger;
    diagnose(): Promise<DoctorCheckResult>;
    fix(): Promise<string>;
    hasAutofix(): boolean;
    isOptional(): boolean;
}
export declare const optionalApplesimutilsCheck: OptionalApplesimutilsCommandCheck;
export declare class OptionalFfmpegCheck implements IDoctorCheck {
    static readonly FFMPEG_BINARY = "ffmpeg";
    static readonly FFMPEG_INSTALL_LINK = "https://www.ffmpeg.org/download.html";
    log: AppiumLogger;
    diagnose(): Promise<DoctorCheckResult>;
    fix(): Promise<string>;
    hasAutofix(): boolean;
    isOptional(): boolean;
}
export declare const optionalFfmpegCheck: OptionalFfmpegCheck;
export declare class OptionalIosRemoteXpcDependencyCheck implements IDoctorCheck {
    static readonly README_LINK = "https://github.com/appium/appium-ios-remotexpc";
    log: AppiumLogger;
    diagnose(): Promise<DoctorCheckResult>;
    fix(): Promise<string>;
    hasAutofix(): boolean;
    isOptional(): boolean;
}
export declare const optionalIosRemoteXpcDependencyCheck: OptionalIosRemoteXpcDependencyCheck;
export declare class OptionalTunnelAvailabilityCheck implements IDoctorCheck {
    static readonly README_LINK = "https://github.com/appium/appium-ios-tuntap";
    static readonly TUNNEL_CREATION_COMMAND = "sudo appium driver run xcuitest tunnel-creation";
    log: AppiumLogger;
    diagnose(): Promise<DoctorCheckResult>;
    fix(): Promise<string>;
    hasAutofix(): boolean;
    isOptional(): boolean;
    /**
     * Returns listening TCP ports. Uses pure Node on Linux (/proc/net/tcp, tcp6); uses netstat on macOS.
     */
    private _getListeningTcpPorts;
    /**
     * Linux: parse /proc/net/tcp and /proc/net/tcp6 (pure Node, no exec). State 0A = LISTEN.
     */
    private _getListeningTcpPortsLinux;
    /**
     * macOS: netstat -anv -p tcp (Node has no API for system-wide listening ports).
     */
    private _getListeningTcpPortsDarwin;
    /**
     * Probes candidate ports for the tunnel registry API in parallel; resolves as soon as any succeed, else null.
     */
    private _probeTunnelRegistry;
    /**
     * Runs the tunnel-creation driver script as a subprocess to avoid blocking doctor if the script hangs.
     * Waits for exit, TUNNEL_SCRIPT_TIMEOUT_MS (5s), or output string indicating registry is up;
     * then evaluates or stops the process.
     */
    private _runTunnelCreationScript;
    /**
     * Interprets tunnel-creation script stdout+stderr and optional exit code; returns the appropriate doctor result.
     * Output pattern matches take priority over a non-zero exit code.
     */
    private _evaluateTunnelScriptOutput;
}
export declare const optionalTunnelAvailabilityCheck: OptionalTunnelAvailabilityCheck;
interface SimulatorPlatform {
    displayName: string;
    name: string;
}
export {};
//# sourceMappingURL=optional-checks.d.ts.map