/**
 * Estimate total throughput by counting bytes received over time interval
 * The estimator receives reports of downloaded chunk sizes and time ranges
 * and calculates total bandwidth accounting for chunks downloaded in parallel
 * and network idle time
 *
 * For example:
 * chunk1:     [___1000___]
 * chunk2:          [_____900_____]
 * chunk3:                                     [___700___]
 * time:      0.2   0.3   0.4    0.5          1.0       1.1
 *           --------------------------------------------------->
 *
 * total size = 1000 + 900 + 700 = 2600
 * active time = (1.1 - 1.0) + (0.5 - 0.2) = 0.4
 * throughput = total size / active time = 6500 bytes/sec
 */
type ILogger = (...args: any[]) => void;
export default class ThroughputEstimator {
    private intervals;
    private currentRate;
    private logger;
    constructor(logger: ILogger);
    private _updateRate;
    private _createInterval;
    private _doMergeIntervals;
    private _mergeIntervals;
    private _flushIntervals;
    private _joinIntervals;
    addInterval(timeStart: number, timeEnd: number, bytes: number): boolean;
    getBitRate(): number;
}
export {};
