Package me.aartikov.replica.client
Types
Link copied to clipboard
Creates and manages replicas.
Link copied to clipboard
Notifies that something happened in ReplicaClient.
Functions
Link copied to clipboard
Cancels network requests in all replicas.
Link copied to clipboard
suspend fun ReplicaClient.cancelByTags(predicate: (Set<ReplicaTag>) -> Boolean)
Content copied to clipboard
Cancels network requests in replicas with the matching tags.
Link copied to clipboard
Cancels network requests and clears data in all replicas.
Link copied to clipboard
suspend fun ReplicaClient.clearByTags(predicate: (Set<ReplicaTag>) -> Boolean)
Content copied to clipboard
Cancels network requests and clears data in replicas with the matching tags.
Link copied to clipboard
suspend fun ReplicaClient.invalidateAll(mode: InvalidationMode = InvalidationMode.RefreshIfHasObservers)
Content copied to clipboard
Makes all replicas stale.
Link copied to clipboard
suspend fun ReplicaClient.invalidateByTags(mode: InvalidationMode = InvalidationMode.RefreshIfHasObservers, predicate: (Set<ReplicaTag>) -> Boolean)
Content copied to clipboard
Makes replicas with the matching tags stale.
Link copied to clipboard
fun ReplicaClient( networkConnectivityProvider: NetworkConnectivityProvider? = null, timeProvider: TimeProvider = RealTimeProvider(), coroutineScope: CoroutineScope = DefaultCoroutineScope): ReplicaClient
Content copied to clipboard
Creates a replica client. Typically, it should be a singleton.