EnvironmentContextBuilderDsl
Builder DSL for creating an environment.This part of the DSL is specifically responsible for creating an EnvironmentContext.
Constructors
Functions
Extensions
Link copied to clipboard
inline fun <T : Any> ContextBuilderDsl.put(noinline supplier: ScopedSupplier<T>): ScopedSupplierDeclaration<T>
Add a definition of type T with the given supplier.
inline fun <T : Any> ContextBuilderDsl.put(qualifier: Qualifier, noinline supplier: ScopedSupplier<T>): ScopedSupplierDeclaration<T>
fun <T : Any> ContextBuilderDsl.put(kclass: KClass<T>, qualifier: Qualifier = EmptyQualifier, supplier: ScopedSupplier<T>): ScopedSupplierDeclaration<T>
Add a definition of type T with the given qualifier and supplier.
Add a definition of type T with the given constructor.
inline fun <T : Any> ContextBuilderDsl.put(qualifier: Qualifier, supplier: KFunction<T>): ScopedSupplierDeclaration<T>
Add a definition of type T with the given qualifier and constructor.
fun <T : Any> ContextBuilderDsl.put(kclass: KClass<T>, supplier: KFunction<T>): ScopedSupplierDeclaration<T>
Add a definition of type T with the given class and constructor.
fun <T : Any> ContextBuilderDsl.put(kclass: KClass<T>, qualifier: Qualifier, supplier: KFunction<T>): ScopedSupplierDeclaration<T>
Add a definition of type T with the given class, qualifier and constructor.
Add a module to the current definition. This adds all the declarations within the module to this context.
Link copied to clipboard
inline fun <TAlias : Any, TTarget : TAlias> ContextBuilderDsl.putAlias(aliasQualifier: Qualifier = EmptyQualifier, targetQualifier: Qualifier = EmptyQualifier): Declaration<TAlias>
fun <TAlias : Any, TTarget : TAlias> ContextBuilderDsl.putAlias(aliasClass: KClass<TAlias>, aliasQualifier: Qualifier = EmptyQualifier, targetClass: KClass<TTarget>, targetQualifier: Qualifier = EmptyQualifier): Declaration<TAlias>
Adds an alias to another component within this environment.
Link copied to clipboard
Allows to put a factory within the module or environment.