runAndGet

@VisibleForTesting(otherwise = 3)
fun runAndGet(source: Int, type: TreeFuture.FutureExecutionType? = null, viewModelStore: LithoViewModelStore? = null): TreeFuture.TreeFutureResult<T>

Synchronously executes the future task, ensuring the result is calculated, and resumed on the main thread if it is interrupted while running on a background thread.

Return

The expected result of calculation, or null if this future was released.

Parameters

source

The calculate-layout source, indicating whether or not it's running from a sync layout.

viewModelStore

An optional store retained while this invocation calculates or waits.