Package-level declarations
Types
Link copied to clipboard
object HttpClient
Link copied to clipboard
class HttpException(val method: HttpMethod, val url: String, val code: Int, val content: String) : Exception
Link copied to clipboard
Link copied to clipboard
class OkHttpProgressInterceptor(progressListener: OkHttpProgressInterceptor.ProgressListener) : Interceptor
Reports how much of a response body has been read.
Link copied to clipboard
data class RetryingJob<T : Any>(val stateFlow: StateFlow<RetryingJob.State<T>>, val producerJob: Job) : Record
Properties
Link copied to clipboard
The HttpException behind this. OkHttp hands one thrown by an interceptor of an async call on wrapped in an IOException.
Link copied to clipboard
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
inline fun <T : Any> CoroutineScope.retrying(interval: Duration, name: String = "data", maxRetries: Int = Int.MAX_VALUE, start: CoroutineStart = CoroutineStart.DEFAULT, crossinline producer: suspend CoroutineScope.() -> T): RetryingJob<T>
Retries a suspending function producer up to maxRetries times with a delay of interval between each retry.
Link copied to clipboard