import { BehaviorSubjectable } from '../abstract/behavior.subjectable'; export declare type ConnectionSpeed = { Bps: number; Kbps: number; Mbps: number; }; /** * ConnectionSpeedSubject * ====================== * * ```typescript * import { ConnectionSpeedSubject } from '@mralexandernickel/frontend.subjects/dist/connection.speed/connection.speed'; * * const connectionSpeed = new ConnectionSpeedSubject('http://domain.tld/path/to/file.jpg', 123456, 2000); * connectionSpeed.get().subscribe(speed => { * if (speed) { * console.log('Connection-SPeed is now:', speed); * } * }); */ export declare class ConnectionSpeedSubject extends BehaviorSubjectable { /** * @constructor * @param file URL to the check-file * @param filesize Size of the check-file * @param interval The duration of the interval to re-check the connection-speed. If this is 0 we will check only once. */ constructor(fileURL: string, fileSize: number, interval?: number); /** * Detect Connection Speed of the client * @param file URL to the check-file * @param filesize Size of the check-file */ private detectConnection; }