Companion

object Companion

Functions

Link copied to clipboard
fun <T> failure(error: Throwable, errorUpdatedAt: Long = epoch()): MutationState<T>
fun <T> failure(error: Throwable, errorUpdatedAt: Long = epoch(), data: T, dataUpdatedAt: Long = epoch(), mutatedCount: Int = 1): MutationState<T>

Creates a new MutationState with the MutationStatus.Failure status.

Link copied to clipboard

Creates a new MutationState with the MutationStatus.Idle status.

Link copied to clipboard

Creates a new MutationState with the MutationStatus.Pending status.

Link copied to clipboard
fun <T> success(data: T, dataUpdatedAt: Long = epoch(), mutatedCount: Int = 1): MutationState<T>

Creates a new MutationState with the MutationStatus.Success status.

Link copied to clipboard
fun <T> test(reply: Reply<T> = Reply.None, replyUpdatedAt: Long = 0, error: Throwable? = null, errorUpdatedAt: Long = 0, status: MutationStatus = MutationStatus.Idle, mutatedCount: Int = 0): MutationState<T>

Creates a new MutationState for Testing.