Logger class
Koin has a simple logging API to log any Koin activity (allocation, lookup ...) Koin proposes some implementation of logging, in function of the target platform:
PrintLogger
- directly log into console (included inkoin-core
)EmptyLogger
- log nothing (included inkoin-core
)
Set logging at start
By default Koin use the EmptyLogger
. You can use directly
the PrintLogger
as following:
startKoin((app){
app.printLogger(level: Level.info);
});
Constructors
- Logger([Level level = Level.info])
-
const
- Logger.empty(Level level)
-
factory
- Logger.print(Level level)
-
factory
Properties
Methods
-
debug(
String msg, {Level level}) → void -
error(
String msg) → void -
info(
String msg) → void -
isAt(
Level level) → bool -
isAtdebug(
String msg, Level isAtLevel) → void -
isAtInfo(
String msg, Level isAtLevel) → void -
isAtLog(
Level level, String msg, Level isAtLevel) → void -
log(
Level level, String msg) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited