koin-core / org.koin.core / KoinApplication

KoinApplication

class KoinApplication

Koin Application Help prepare resources for Koin context

Author
Arnaud Giuliani

Properties

koin

val koin: Koin

Functions

close

fun close(): Unit

Close all resources from Koin & remove Standalone Koin instance

createEagerInstances

fun createEagerInstances(): KoinApplication

Create Single instances Definitions marked as createdAtStart

environmentProperties

fun environmentProperties(): KoinApplication

Load properties from environment

fileProperties

fun fileProperties(fileName: String = "/koin.properties"): KoinApplication

Load properties from file

logger

fun logger(logger: Logger): KoinApplication

Set Koin Logger

modules

fun modules(vararg modules: Module): KoinApplication
fun modules(modules: Iterable<Module>): KoinApplication

Load definitions from modules

printLogger

fun printLogger(level: Level = Level.INFO): KoinApplication

Set Koin to use PrintLogger, by default at Level.INFO

properties

fun properties(values: Map<String, Any>): KoinApplication

Load properties from Map

unloadModules

fun unloadModules(vararg modules: Module): KoinApplication
fun unloadModules(modules: List<Module>): KoinApplication

Companion Object Properties

logger

var logger: Logger

Companion Object Functions

create

fun create(): KoinApplication

Create a new instance of KoinApplication