downloadFile

abstract suspend fun downloadFile(fileDescriptor: RainbowFileDescriptor): RainbowResult<RainbowFileDescriptor>

Download the file from the server. This method uses the Android DownloadManager

See cancelDownload to cancel the download

Return

RainbowResult callback (onSuccess, onError)

Parameters

fileDescriptor

RainbowFileDescriptor associated with the file to download, the fileDescriptor keeps track of the download progression with the method getPercentProgression()