Joutsen Logging v0.5.0+26-g72240ac
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Properties | List of all members
Joutsen.Logging.DefaultLogger Class Reference

The default implementation of a logger. More...

Public Member Functions

 DefaultLogger ()
 
void AddHandler (Handler handler)
 Adds a new output handler which will be notified whenever a log record should be written.
 
void RemoveHandler (Handler handler)
 Removes an output handler that should no longer be notified to write log records.
 
override void Dispose ()
 Frees all handlers and resources.
 
- Public Member Functions inherited from Joutsen.Logging.AbstractLogger
void Dispose ()
 
virtual Guid Log (LogRecord record)
 Logs a record.
 
Guid Log (LogLevel level, string message, params object[] parameters)
 Logs a message of a specific log level.
 
Guid Log (LogLevel level, string message, object parameter)
 Logs a message of a specific log level.
 
Guid Log (LogLevel level, string message, Map< string, object > parameters)
 Logs a message of a specific log level.
 
Guid Log (LogLevel level, string message, IEnumerable listParameter)
 Logs a message of a specific log level with a list as parameter.
 
Guid Error (Exception exception, string message, Map< string, object > parameters)
 Logs an exception with an additional message.
 
Guid Error (Exception exception, string message, object parameter)
 Logs an exception with an additional message.
 
Guid Error (Exception exception, string message, params object[] parameters)
 Logs an exception with an additional message.
 
Guid Error (Exception exception)
 Logs an System.Exception as an error.
 
Guid Error (string message, Map< string, object > parameters)
 Logs an error message with parameters.
 
Guid Error (string message, object parameter)
 Logs an error message with parameters.
 
Guid Error (string message, params object[] parameters)
 Logs an error message with parameters.
 
Guid Error (string message, IEnumerable listParameter)
 Logs an error message with a list.
 
Guid Warning (string message, Map< string, object > parameters)
 Logs a warning message with parameters.
 
Guid Warning (string message, object parameter)
 Logs a warning message with parameters.
 
Guid Warning (string message, params object[] parameters)
 Logs a warning message with parameters.
 
Guid Warning (string message, IEnumerable listParameter)
 Logs an warning message with a list.
 
Guid Info (string message, Map< string, object > parameters)
 Logs an informational message with parameters.
 
Guid Info (string message, object parameter)
 Logs an informational message with parameters.
 
Guid Info (string message, params object[] parameters)
 Logs an informational message with parameters.
 
Guid Info (string message, IEnumerable listParameter)
 Logs an informational message with a list.
 
Guid Detail (string message, Map< string, object > parameters)
 Logs a detail message with parameters.
 
Guid Detail (string message, object parameter)
 Logs a detail message with parameters.
 
Guid Detail (string message, params object[] parameters)
 Logs a detail message with parameters.
 
Guid Detail (string message, IEnumerable listParameter)
 Logs a detail message with a list.
 
Guid Verbose (string message, Map< string, object > parameters)
 Logs a verbose message with parameters.
 
Guid Verbose (string message, object parameter)
 Logs a verbose message with parameters.
 
Guid Verbose (string message, params object[] parameters)
 Logs a verbose message with parameters.
 
Guid Verbose (string message, IEnumerable listParameter)
 Logs a verbose message with a list.
 

Protected Member Functions

override bool IsLoggable (LogRecord record)
 Checks if a record is loggabe by this instance of a logger.
 

Properties

virtual Filter Filter [get, set]
 The filter for the records passed to the logger.
 

Additional Inherited Members

- Events inherited from Joutsen.Logging.AbstractLogger
Action< LogRecord > Publish
 

Detailed Description

The default implementation of a logger.

Since
0.2.0

Constructor & Destructor Documentation

◆ DefaultLogger()

Joutsen.Logging.DefaultLogger.DefaultLogger ( )

Member Function Documentation

◆ AddHandler()

void Joutsen.Logging.DefaultLogger.AddHandler ( Handler  handler)

Adds a new output handler which will be notified whenever a log record should be written.

Parameters
handlerthe handler to be added

◆ Dispose()

override void Joutsen.Logging.DefaultLogger.Dispose ( )

Frees all handlers and resources.

◆ IsLoggable()

override bool Joutsen.Logging.DefaultLogger.IsLoggable ( LogRecord  record)
protectedvirtual

Checks if a record is loggabe by this instance of a logger.

Reimplemented from Joutsen.Logging.AbstractLogger.

◆ RemoveHandler()

void Joutsen.Logging.DefaultLogger.RemoveHandler ( Handler  handler)

Removes an output handler that should no longer be notified to write log records.

Parameters
handlerthe handler to be removed

Property Documentation

◆ Filter

virtual Filter Joutsen.Logging.DefaultLogger.Filter
getset

The filter for the records passed to the logger.

Only entries which pass the filter are processed.