Common Logging 2.0 API Reference

LogManager.GetCurrentClassLogger Method

Gets the logger by calling GetLogger on the currently configured Adapter using the type of the calling class.

[Visual Basic]
Public Shared Sub GetCurrentClassLogger()
[C#]
public static ILog GetCurrentClassLogger();

Return Value

the logger instance obtained from the current Adapter

Remarks

This method needs to inspect the StackTrace in order to determine the calling class. This of course comes with a performance penalty, thus you shouldn't call it too often in your application.

See Also

LogManager Class | Common.Logging Namespace | GetLogger