Skip to content

Index

hexagon_core / com.hexagonkt.injection / InjectionManager

InjectionManager

object InjectionManager

Generators registry and utilities. This object keep tracks of supplier functions or specific objects bound to classes. Different suppliers can be bound to the same type using 'tags'.

Functions

Name Summary
bind fun <T :Any, R : T> bind(type:KClass<T>, provider:Provider<R>, tag:Any= Unit):Unit
fun <T :Any, R : T> bind(type:KClass<T>, tag:Any= Unit, provider: () -> R):Unit
fun <T :Any, R : T> bind(type:KClass<T>, provider: () -> R):Unit
fun <T :Any, R : T> bind(type:KClass<T>, instance: R, tag:Any= Unit):Unit
fun <T :Any, R : T> bind(type:KClass<T>, instance: R):Unit
fun <T :Any> bind(tag:Any, provider: () -> T):Unit
fun <T :Any> bind(provider: () -> T):Unit
fun <T :Any> bind(instance: T, tag:Any= Unit):Unit
fun <T :Any, R : T> bind(type:KClass<T>, providers:List<() -> R>):Unit
fun <T :Any> bind(providers:List<() -> T>):Unit
fun <T :Any, R : T> bind(type:KClass<T>, providers:Map<Any, () -> R>):Unit
fun <T :Any> bind(providers:Map<Any, () -> T>):Unit
bindSet fun <T :Any, R : T> bindSet(type:KClass<T>, instances:List<R>):Unit
fun <T :Any> bindSet(instances:List<T>):Unit
fun <T :Any, R : T> bindSet(type:KClass<T>, instances:Map<Any, R>):Unit
fun <T :Any> bindSet(instances:Map<Any, T>):Unit
inject fun <T :Any> inject(type:KClass<T>, tag:Any): T
fun <T :Any> inject(tag:Any): T
fun <T :Any> inject(type:KClass<T>): T
fun <T :Any> inject(): T
injectList fun <T :Any> injectList(type:KClass<T>):List<T>
injectMap fun <T :Any> injectMap(type:KClass<T>):Map<Any, T>
injectOrNull fun <T :Any> injectOrNull(type:KClass<T>, tag:Any): T?
fun <T :Any> injectOrNull(tag:Any): T?
fun <T :Any> injectOrNull(type:KClass<T>): T?
fun <T :Any> injectOrNull(): T?
toString fun toString():String

Comments