Package-level declarations

Types

Link copied to clipboard
fun interface Connectable<I, O>

API for something that can be connected to be part of a MobiusLoop.

Link copied to clipboard
interface Connection<I> : Disposable, Consumer<I>

Handle for a connection created by Connectable.

Link copied to clipboard
class ConnectionException(val effect: Any, throwable: Throwable) : RuntimeException

Indicates that a Connectable connection caused an unhandled exception.

Link copied to clipboard
class ConnectionLimitExceededException @JvmOverloads constructor(message: String? = null, throwable: Throwable? = null) : RuntimeException

Exception to be thrown by a Connectable that doesn't support multiple simultaneous connections.

Link copied to clipboard

A Connectable that ensures that Connections created by the wrapped Connectable don't emit or receive any values after being disposed.

Link copied to clipboard

Wraps a Connection or a Consumer and blocks them from receiving any further values after the wrapper has been disposed.

Link copied to clipboard
object Effects

Utility class for working with effects.

Link copied to clipboard
fun interface EventSource<E>

Interface for event sources.

Link copied to clipboard
Link copied to clipboard
data class First<M, F>

Defines the entry into the initial state of a Mobius loop.

Link copied to clipboard
fun interface Init<M, F>

An interface representing the Init function used by Mobius for starting or resuming execution of a program from a given model.

Link copied to clipboard
class LoggingInit<M, F> : Init<M, F>
Link copied to clipboard

An EventSource that merges multiple sources into one

Link copied to clipboard
object Mobius
Link copied to clipboard

Allows configuration of how Mobius handles programmer errors through setting a custom ErrorHandler via the setErrorHandler method. The default handler prints errors with println.

Link copied to clipboard

This is the main loop for Mobius.

Link copied to clipboard
class Next<M, F>

This class represents the result of calling an Update function.

Link copied to clipboard
class SafeConnectable<F, E>(actual: Connectable<F, E>) : Connectable<F, E>

A Connectable that ensures that an inner Connection doesn't emit or receive any values after being disposed.

Link copied to clipboard
class SimpleLogger<M, E, F>(tag: String) : MobiusLoop.Logger<M, E, F>

A basic MobiusLoop.Logger implementation backed by the current MobiusHooks.InternalLogger.

Link copied to clipboard
fun interface Update<M, E, F>

An interface representing the Update function used by Mobius for performing model transitions and requesting side-effects.