C# Class HourBoostr.Log

Afficher le fichier Open project: Ezzpify/HourBoostr

Méthodes publiques

Свойство Type Description
mLogName string

Méthodes publiques

Méthode Description
Log ( string logName, string logPath, int queueSize ) : System

Class constructor Initializes the log file

Write ( LogLevel level, string str, bool logToFile = true, bool writeToConsole = true, bool rawMessage = false ) : void

Writes a log message

Private Methods

Méthode Description
FlushLog ( ) : void

Flushes the log to file

GetTimestamp ( ) : string

Returns a datetime timestmap

Method Details

Log() public méthode

Class constructor Initializes the log file
public Log ( string logName, string logPath, int queueSize ) : System
logName string Log name to easier recognize which log is speaking
logPath string Path to log file
queueSize int How many log entries we keep before flushing file
Résultat System

Write() public méthode

Writes a log message
public Write ( LogLevel level, string str, bool logToFile = true, bool writeToConsole = true, bool rawMessage = false ) : void
level LogLevel Level of message
str string String to write
logToFile bool If we should write message to log file
writeToConsole bool
rawMessage bool
Résultat void

Property Details

mLogName public_oe property

Name of the log file
public string mLogName
Résultat string