UNPKG

andrade-soulseek-downloader

Version:

Simple, safe Soulseek download library with built-in rate limiting to prevent bans

41 lines 1.3 kB
/** * Value object representing audio bitrate in kbps. * Provides quality classification and scoring logic. */ export declare class Bitrate { private readonly value; /** * @param value - Bitrate in kbps (0-9999) * @throws {Error} If value is out of range */ constructor(value: number); /** @returns Bitrate value in kbps */ getValue(): number; /** * Classifies bitrate into quality tiers. * @returns Quality level based on bitrate value */ getQualityLevel(): 'LOSSLESS' | 'HIGH' | 'MEDIUM' | 'LOW'; /** * Converts bitrate to quality score points. * @returns Points from 0-50 for quality scoring */ toQualityPoints(): number; /** @returns True if bitrate is 320kbps or higher */ isHighQuality(): boolean; /** @returns True if bitrate indicates lossless audio (>1000kbps) */ isLossless(): boolean; /** * @param other - Bitrate to compare with * @returns True if bitrates are equal */ equals(other: Bitrate): boolean; /** * @param other - Bitrate to compare with * @returns True if this bitrate is higher */ isHigherThan(other: Bitrate): boolean; /** @returns Human-readable bitrate string */ toString(): string; } //# sourceMappingURL=bitrate.d.ts.map