Package com.codingchili.core.context
Class StringLogger
java.lang.Object
java.util.logging.Handler
com.codingchili.core.logging.AbstractLogger
com.codingchili.core.logging.ConsoleLogger
com.codingchili.core.context.StringLogger
- All Implemented Interfaces:
JsonLogger
,Logger
A simple logger without any metadata, replacement for System.out.
-
Field Summary
Fields inherited from class com.codingchili.core.logging.AbstractLogger
aClass, context, logger, metadata
-
Constructor Summary
ConstructorDescriptionStringLogger(CoreContext context, Class aClass)
StringLogger(Class aClass)
-
Method Summary
Methods inherited from class com.codingchili.core.logging.ConsoleLogger
close, consumeLevel, getFilteredKeys, log, setEnabled
Methods inherited from class com.codingchili.core.logging.AbstractLogger
event, event, flush, log, log, onAlreadyInitialized, onCacheCleared, onConfigurationDefaultsLoaded, onError, onFileLoaded, onFileLoadError, onFileSaved, onFileSaveError, onHandlerMissing, onInvalidConfigurable, onListenerStarted, onListenerStopped, onMetricsSnapshot, onSecurityDependencyMissing, onServiceFailed, onServiceStarted, onServiceStopped, onTimerSourceChanged, publish, removeMetadata, setMetadata, setMetadataValue
Methods inherited from class java.util.logging.Handler
getEncoding, getErrorManager, getFilter, getFormatter, getLevel, isLoggable, reportError, setEncoding, setErrorManager, setFilter, setFormatter, setLevel
-
Constructor Details
-
StringLogger
- Parameters:
aClass
- the class that uses this logger.
-
StringLogger
- Parameters:
context
- the context the logger is used on.aClass
- the class that uses this logger.
-
-
Method Details
-
parseJsonLog
- Overrides:
parseJsonLog
in classConsoleLogger
-
log
- Parameters:
line
- the text line to be logged.- Returns:
- fluent
-
log
- Parameters:
line
- the text line to be logged.level
- the logging level to log with.- Returns:
- fluent
-