android-beans / rocks.frieler.android.beans.scopes.activity / activityScopedBean

activityScopedBean

inline fun <reified T : Any> DeclarativeBeanConfiguration.activityScopedBean(name: String? = null, noinline definition: BeansProvider.() -> T): Unit

Adds a BeanDefinition for an ActivityScopedFactoryBean that produces a bean with the given definition, optionally with the specified name.

Parameters

name - the bean's name (optional)

definition - the definition to construct the bean

Parameters