The ILog interface is use by application to log messages into the log4net framework.
For a list of all members of this type, see ILog Members.
Use the LogManager to obtain logger instances that implement this interface. The GetLogger static method is used to get logger instances.
This class contains methods for logging at different levels and also has properties for determining if those logging levels are enabled in the current configuration.
This interface can be implemented in different ways. This documentation specifies reasonable behavior that a caller can expect from the actual implementation, however different implementations reserve the right to do things differently.
Simple example of logging messages
[C#]
ILog log = LogManager.GetLogger("application-log");
log.Info("Application Start");
log.Debug("This is a debug message");
if (log.IsDebugEnabled)
{
log.Debug("This is another debug message");
}
Namespace: log4net
Assembly: log4net (in log4net.dll)
ILog Members | log4net Namespace | LogManager | GetLogger