Package-level declarations

Types

Link copied to clipboard
class OneTimeEvent<T>(content: T)

A thread-safe wrapper for one-time events that should be consumed only once, even when observed multiple times.

Link copied to clipboard
sealed class Resource<T>

A sealed class that represents the result of a resource operation with loading, success, and error states.

Link copied to clipboard
interface StringDecoder

Interface representing a string decoder.

Link copied to clipboard
class UriDecoder @Inject constructor : StringDecoder

Implementation of StringDecoder that uses Android's Uri.decode method for decoding strings.

Link copied to clipboard
@DaggerGenerated
@Generated(value = "dagger.internal.codegen.ComponentProcessor", comments = "https://dagger.dev")
class UriDecoder_Factory : Factory<UriDecoder>
@DaggerGenerated
@Generated(value = "dagger.internal.codegen.ComponentProcessor", comments = "https://dagger.dev")
class UriDecoder_Factory : Factory<UriDecoder>

Functions

Link copied to clipboard
inline fun <ResultType, RequestType> networkBoundResource(crossinline query: () -> Flow<ResultType>, crossinline fetch: suspend () -> RequestType, crossinline saveFetchedResult: suspend (RequestType) -> Unit, crossinline shouldFetch: (ResultType) -> Boolean = { true }): Flow<Resource<ResultType>>

Creates a network-bound resource flow that implements the offline-first pattern.

Link copied to clipboard
inline suspend fun <T> suspendCoroutineWithTimeout(timeMillis: Long, crossinline block: (CancellableContinuation<T>) -> Unit): T

Suspends the current coroutine with a timeout in milliseconds, useful for operations that need time-based cancellation.

inline suspend fun <T> suspendCoroutineWithTimeout(timeout: Duration, crossinline block: (Continuation<T>) -> Unit): T

Suspends the current coroutine with a timeout, useful for operations that need time-based cancellation.

Link copied to clipboard
inline suspend fun <T> suspendRunCatching(crossinline block: suspend () -> T): Result<T>

Executes a suspending operation and returns the result wrapped in Result, with proper coroutine cancellation handling.