Skip to content

LiteFX::Logging::RollingFileSink::RollingFileSink

Creates a new rolling file sink instance.

Synopsis

Declared in <litefx/logging.hpp>

[[dllexport, dllimport]] RollingFileSink(
    String const& fileName,
    LogLevel level = LogLevel::Info,
    String const& pattern = "%+",
    bool truncate = false,
    int maxFiles = 0);

Parameters

NameDescription
fileNameThe name of the log file.
levelThe minimum log level for messages to be saved to the file.
patternThe default format for log messages.
truncatetrue, if the log messages should be truncated to the contents of the file. false to overwrite existing messages.
maxFilesThe maximum number of files to keep.