DownloadFileToMemoryUseCase

Downloads a file entirely into memory, never touching the filesystem — backs DownloadFileToMemory. Reachable via get<DownloadFileToMemoryUseCase>().

Constructors

Link copied to clipboard
constructor(repository: MosaicRepository)

Types

Link copied to clipboard
data class Params(val url: String, val headers: Map<String, String>?, val body: Any?, val httpMethod: HttpMethod, val onProgress: suspend (Float) -> Unit = {}, val onDownloadFinished: suspend (ByteArray) -> Unit = {}, val onDownloadFailure: suspend (Throwable) -> Unit = {})

Functions

Link copied to clipboard
open suspend override fun execute(params: DownloadFileToMemoryUseCase.Params): Result<Unit>
Link copied to clipboard
suspend operator fun invoke(params: DownloadFileToMemoryUseCase.Params): Result<Unit>