CacheableQueryWithInput

class CacheableQueryWithInput<TInput : CacheableInput.QueryInput, TData, TError : Throwable>(coroutineScope: CoroutineScope, launchQuery: suspend (input: TInput) -> TData?, startingCacheKey: TInput? = null, cache: OnHandCache, dispatcher: CoroutineDispatcher = Dispatchers.Default, ttl: Duration? = null, initialFetchState: FetchState = FetchState.IDLE)

Constructors

Link copied to clipboard
constructor(coroutineScope: CoroutineScope, launchQuery: suspend (input: TInput) -> TData?, startingCacheKey: TInput? = null, cache: OnHandCache, dispatcher: CoroutineDispatcher = Dispatchers.Default, ttl: Duration? = null, initialFetchState: FetchState = FetchState.IDLE)

Properties

Link copied to clipboard

Functions

Link copied to clipboard
operator fun component1(): StateFlow<CacheableQueryResult<TData, TError>>
Link copied to clipboard
suspend fun fetch(queryInput: TInput, onSuccess: suspend (TData) -> Unit? = null, onError: suspend (TError) -> Unit? = null)