public class TinylogLoggingConfiguration
extends java.lang.Object
LogEntry
for writers.Constructor | Description |
---|---|
TinylogLoggingConfiguration() |
Modifier and Type | Method | Description |
---|---|---|
protected void |
addWriter(Writer writer,
java.util.Collection<Writer>[][] matrix,
int tagIndex,
org.tinylog.Level level) |
Adds a writer to a well-defined matrix.
|
java.util.BitSet |
calculateFullStackTraceRequirements(java.util.Collection<LogEntryValue>[][] logEntryValues) |
Calculates for which tag a full stack trace element with method name, file name and line number is required.
|
org.tinylog.Level |
calculateMinimumLevel(org.tinylog.Level globalLevel,
java.util.Map<java.lang.String,org.tinylog.Level> customLevels) |
Calculates the minimum severity level that can output any log entries.
|
java.util.Collection<LogEntryValue>[][] |
calculateRequiredLogEntryValues(java.util.Collection<Writer>[][] writers) |
Creates a matrix with all required log entry values for each tag and severity level.
|
static LogEntry |
createLogEntry(java.lang.StackTraceElement stackTraceElement,
java.lang.String tag,
org.tinylog.Level level,
java.lang.Throwable exception,
org.tinylog.format.MessageFormatter formatter,
java.lang.Object obj,
java.lang.Object[] arguments,
java.util.Collection<LogEntryValue>[] requiredLogEntryValues,
org.tinylog.provider.ContextProvider contextProvider) |
Creates a new log entry.
|
java.util.Collection<Writer>[][] |
createWriters(java.util.List<java.lang.String> tags,
org.tinylog.Level minimumLevel,
boolean writingThread) |
Creates a two-dimensional matrix with all configured writers.
|
WritingThread |
createWritingThread(java.util.Collection<Writer>[][] matrix) |
Creates a writing thread for a matrix of writers.
|
static java.util.Collection<Writer> |
getAllWriters(java.util.Collection<Writer>[][] matrix) |
Collects all writer instances from a matrix of writers.
|
public java.util.Collection<Writer>[][] createWriters(java.util.List<java.lang.String> tags, org.tinylog.Level minimumLevel, boolean writingThread)
Level.TRACE
and ends with Level.ERROR
.tags
- Order of defined tagsminimumLevel
- Minimum global severity levelwritingThread
- Defines whether WritingThread
is enabledprotected void addWriter(Writer writer, java.util.Collection<Writer>[][] matrix, int tagIndex, org.tinylog.Level level)
writer
- Writer to addmatrix
- Well-defined two-dimensional matrixtagIndex
- Represents the tag (first dimension of matrix)level
- Represents the severity level (second dimension of matrix)public org.tinylog.Level calculateMinimumLevel(org.tinylog.Level globalLevel, java.util.Map<java.lang.String,org.tinylog.Level> customLevels)
globalLevel
- Global severity levelcustomLevels
- Custom severity levels for packages and classespublic java.util.Collection<LogEntryValue>[][] calculateRequiredLogEntryValues(java.util.Collection<Writer>[][] writers)
writers
- Matrix with registered writerspublic java.util.BitSet calculateFullStackTraceRequirements(java.util.Collection<LogEntryValue>[][] logEntryValues)
logEntryValues
- Matrix with required log entry valuespublic WritingThread createWritingThread(java.util.Collection<Writer>[][] matrix)
matrix
- All writerspublic static java.util.Collection<Writer> getAllWriters(java.util.Collection<Writer>[][] matrix)
matrix
- All writerspublic static LogEntry createLogEntry(java.lang.StackTraceElement stackTraceElement, java.lang.String tag, org.tinylog.Level level, java.lang.Throwable exception, org.tinylog.format.MessageFormatter formatter, java.lang.Object obj, java.lang.Object[] arguments, java.util.Collection<LogEntryValue>[] requiredLogEntryValues, org.tinylog.provider.ContextProvider contextProvider)
stackTraceElement
- Optional stack trace element of callertag
- Tag name if issued from a tagged loggerlevel
- Severity levelexception
- Caught exception or throwable to logformatter
- Formatter for text messageobj
- Message to logarguments
- Arguments for messagerequiredLogEntryValues
- The required log entry value array slice of the tag index of the used tagcontextProvider
- The context providerCopyright © 2022. All rights reserved.