Package-level declarations

Types

Link copied to clipboard
open class Context : Disposable

Handles dependency injection mechanism. Allows binding selected classes with their providers.

Link copied to clipboard
class InjectionException(message: String, cause: Throwable? = null) : RuntimeException

Thrown in case of any problems with the dependency injection mechanism.

Link copied to clipboard
data class SingletonProvider<out Type : Any>(val singleton: Type) : Disposable, Function0<Type>

Wraps singletons registered in a Context, allowing to dispose them.

Functions

Link copied to clipboard
inline fun Context.register(init: Context.() -> Unit): Context

Allows to register new components in the context with builder-like DSL.