import { BaseMonitor } from '../core/base-monitor';
import { MonitorResult, NetworkConfig, NetworkInterface, NetworkStats, DataSize } from '../types';
import { PlatformAdapter } from '../types/platform';
import { CacheManager } from '../core/cache-manager';
/**
 * 网络监控器
 *
 * 提供网络相关的监控功能，包括接口信息、流量统计、连接状态等
 */
export declare class NetworkMonitor extends BaseMonitor<NetworkInterface[]> {
    private networkConfig;
    constructor(adapter: PlatformAdapter, config?: NetworkConfig, cache?: CacheManager);
    /**
     * 获取网络接口信息（实现抽象方法）
     */
    info(): Promise<MonitorResult<NetworkInterface[]>>;
    /**
     * 获取网络接口信息
     */
    interfaces(): Promise<MonitorResult<NetworkInterface[]>>;
    /**
     * 获取指定接口信息
     */
    interfaceByName(name: string): Promise<MonitorResult<NetworkInterface | null>>;
    /**
     * 获取网络统计信息（异步版本）
     */
    statsAsync(options?: {
        skipCache?: boolean;
    }): Promise<MonitorResult<NetworkStats[]>>;
    /**
     * 获取指定接口的统计信息
     */
    statsByInterface(interfaceName: string): Promise<MonitorResult<NetworkStats | null>>;
    /**
     * 获取带宽使用情况（需要两次测量）
     */
    bandwidth(): Promise<MonitorResult<{
        interval: number;
        interfaces: Array<{
            interface: string;
            rxSpeed: number;
            txSpeed: number;
            rxSpeedFormatted: string;
            txSpeedFormatted: string;
        }>;
    }>>;
    /**
     * 获取活跃的网络连接
     */
    connections(): Promise<MonitorResult<any[]>>;
    /**
     * 获取默认网关信息
     */
    gateway(): Promise<MonitorResult<{
        gateway: string | null;
        interface: string;
    } | null>>;
    /**
     * 获取公网 IP 地址
     */
    publicIP(): Promise<MonitorResult<{
        ipv4?: string;
        ipv6?: string;
    }>>;
    /**
     * 网络健康检查
     */
    healthCheck(): Promise<MonitorResult<{
        status: 'healthy' | 'warning' | 'critical';
        issues: string[];
        checks: {
            interfaceStatus: boolean;
            connectivity: boolean;
            performance: boolean;
        };
    }>>;
    /**
     * 获取网络总览信息
     */
    overview(): Promise<MonitorResult<{
        interfaces: number;
        activeInterfaces: number;
        totalRxBytes: DataSize;
        totalTxBytes: DataSize;
        totalPackets: number;
        totalErrors: number;
    }>>;
    /**
     * 配置是否包含接口统计
     */
    withInterfaceStats(include: boolean): this;
    /**
     * 配置是否包含连接信息
     */
    withConnections(include: boolean): this;
    /**
     * 配置是否包含带宽监控
     */
    withBandwidth(include: boolean): this;
    /**
     * 配置目标网络接口
     */
    withInterfaces(interfaces: string[]): this;
    /**
     * 配置带宽监控间隔
     */
    withBandwidthInterval(interval: number): this;
    /**
     * 获取默认配置
     */
    protected getDefaultConfig(): NetworkConfig;
    /**
     * 转换网络接口信息
     */
    /**
     * 将平台适配器返回的原始接口数据统一转换为 NetworkInterface 结构
     * 支持 Node.js os.networkInterfaces() 返回的对象以及适配器自定义的数组格式
     */
    private transformNetworkInterfaces;
    /**
     * 转换网络统计信息
     */
    private transformNetworkStats;
    /**
     * 转换网络连接信息
     */
    private transformNetworkConnections;
    /**
     * 转换网关信息
     */
    private transformGatewayInfo;
    /**
     * 计算带宽
     */
    private calculateBandwidth;
    /**
     * 推断接口状态
     */
    private inferInterfaceState;
    /**
     * 推断接口类型
     */
    private inferInterfaceType;
    /**
     * 判断是否应该包含该接口
     */
    private shouldIncludeInterface;
    private normalizeInterfaceState;
    /**
     * 安全解析数字
     */
    private safeParseNumber;
    /**
     * 获取网络流量统计（同步版本，向后兼容）
     * @param interval 监控间隔（毫秒）
     * @returns 网络流量统计对象或 'not supported'
     */
    inOut(interval?: number): any;
    /**
     * 获取网络统计信息（同步版本，向后兼容）
     * @returns 网络统计信息数组或 'not supported'
     */
    stats(): any;
}
//# sourceMappingURL=network-monitor.d.ts.map