IDataSource

interface IDataSource

Inheritors

Properties

Link copied to clipboard
abstract val loadState: Flow<LoadState>

Observable for network state during requests that the UI can monitor and act based on state changes

Link copied to clipboard

Request helper that controls the flow of requests to the implementing data source to avoid multiple requests of the same type before others are completed for this instance

Functions

Link copied to clipboard
infix fun <T> IDataSource.create(model: Flow<T>): DataState<T>

Helper for creating a user interface state using a data source

Link copied to clipboard
abstract suspend fun refresh()

Invalidate data source and, re-run the last successful or last failed request if applicable

Link copied to clipboard
abstract suspend fun retryFailed()

Performs the necessary operation to invoke a network retry request