FimberFileTree class

File based logging output tree. This tree if planted will post short formatted (elapsed time and message) output into file specified in constructor. Note: Mostly for testing right now

Inheritance
Mixed in types
Implementers

Constructors

FimberFileTree(String outputFileName, {dynamic logLevels = CustomFormatTree.defaultLevels, dynamic logFormat = '${CustomFormatTree.timeStampToken}' '\t${CustomFormatTree.messageToken}', int maxBufferSize = bufferSizeLimit, int bufferWriteInterval = fileBufferFlushInterval})
Creates Instance of FimberFileTree with optional logFormat from CustomFormatTree predicates. Takes optional maxBufferSize (default 1kB) and optional bufferWriteInterval in milliseconds.
FimberFileTree.elapsed(String fileName, {List<String> logLevels = CustomFormatTree.defaultLevels})
Creates Fimber File tree with time tracking as elapsed from start of the process.
factory

Properties

colorizeMap Map<String, ColorizeStyle>
Map of log levels and their colorizing style.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
logFormat String
Log line format style.
getter/setter pairinherited
outputFileName String
Output current log file name.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

close() → void
Closes a tree, use it to flush buffer/caches or close any resource.
override
getLevels() List<String>
Gets levels of logging serviced by this LogTree
inherited
log(String level, String msg, {String? tag, dynamic ex, StackTrace? stacktrace}) → void
Logs a message with level/tag and optional stacktrace or exception.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
printLine(String line, {String? level}) → void
Prints log line with optional log level.
override
printLog(String logLine, {String? level}) → void
Method to overload printing to output stream the formatted logline Adds handing of time
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

bufferSizeLimit → const int
Size limit (bytes) in temporary buffer.
fileBufferFlushInterval → const int
Interval for buffer write to file. In milliseconds