Tracker<TrackableType extends Trackable> class

A logger that tracks a sequence of Trackable events into multiple output formats.

By default, Tracker outputs to both a ASCII table format (.tracker.log) and a JSON format (.tracker.json).

Constructors

Tracker(String name, List<TrackerField> fields, {String spacer = ' | ', String separator = '-', String overflow = '*', String? outputFolder, bool dumpTable = true, bool dumpJson = true})
Constructs a Tracker named name with the provided fields.

Properties

dumpJson bool
If true, will dump a JSON file log to jsonFileName.
final
dumpTable bool
If true, will dump an ASCII table log to tableFileName.
final
hashCode int
The hash code for this object.
read-onlyinherited
jsonFileName String
The path to the generated JSON log file, if enabled by dumpJson.
read-only
name String
The name of this Tracker, used for naming output files.
final
outputFolder String?
An optional output directory for the logs.
final
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
tableFileName String
The path to the generated ASCII table log file, if enabled by dumpTable.
read-only

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
record(TrackableType trackable, {Map<String, String?> defaults = const {}}) → void
Records trackable into all enabled logs.
terminate() Future<void>
Cleans up and finalizes all logs.
toString() String
A string representation of this object.
inherited

Operators

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