Builder

class Builder<E, R>

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
Link copied to clipboard
lateinit var config: FusClientConfig
Link copied to clipboard
var parentScope: CoroutineScope

Parent scope for the FusClient, which creates a child scope from it to isolate crashes. Pass a custom scope to use a dispatcher other than Dispatchers.Default.

Functions

Link copied to clipboard
fun build(): FusClient<E, R>
Link copied to clipboard

Configures the FusClient components. Include defaultBusinessLogic from com.jetbrains.fus.reporting.defaults and the DFL functions displayed below.

Link copied to clipboard

Jump to the source of FusClientConfig.Builder for the configuration options.

Link copied to clipboard
fun <T : Any> FusClient.Builder<*, *>.messageHandler(topic: Topic<T>, errorHandler: (Throwable) -> Unit = {}, handle: suspend (message: T) -> Unit)

Registers a callback that runs asynchronously when the step identified by topic occurs inside the FusClient. Message handlers can run concurrently, so shared resources must be thread-safe.