ILogger<TCategoryName> Interface
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents a logger that can be used for logging messages with a specific category.
public interface ILogger<out TCategoryName> : Microsoft.Testing.Platform.Logging.ILogger
type ILogger<'CategoryName> = interface
interface ILogger
Public Interface ILogger(Of Out TCategoryName)
Implements ILogger
Type Parameters
- TCategoryName
The type of the category name.
This type parameter is covariant. That is, you can use either the type you specified or any type that is more derived. For more information about covariance and contravariance, see Covariance and Contravariance in Generics.- Implements
Methods
| Name | Description |
|---|---|
| IsEnabled(LogLevel) |
Checks if the logger is enabled for the specified log level. (Inherited from ILogger) |
| Log<TState>(LogLevel, TState, Exception, Func<TState,Exception,String>) |
Logs a message with the specified log level, state, exception, and formatter. (Inherited from ILogger) |
| LogAsync<TState>(LogLevel, TState, Exception, Func<TState,Exception,String>) |
Asynchronously logs a message with the specified log level, state, exception, and formatter. (Inherited from ILogger) |
Extension Methods
| Name | Description |
|---|---|
| LogCritical(ILogger, String) |
Logs a message with the critical log level. |
| LogCriticalAsync(ILogger, String) |
Logs a message with the critical log level. |
| LogDebug(ILogger, String) |
Logs a message with the debug log level. |
| LogDebugAsync(ILogger, String) |
Logs a message with the debug log level. |
| LogError(ILogger, Exception) |
Logs a message with the error log level. |
| LogError(ILogger, String, Exception) |
Logs a message with the error log level. |
| LogError(ILogger, String) |
Logs a message with the error log level. |
| LogErrorAsync(ILogger, Exception) |
Logs a message with the error log level. |
| LogErrorAsync(ILogger, String, Exception) |
Logs a message with the error log level. |
| LogErrorAsync(ILogger, String) |
Logs a message with the error log level. |
| LogInformation(ILogger, String) |
Logs a message with the info log level. |
| LogInformationAsync(ILogger, String) |
Logs a message with the info log level. |
| LogTrace(ILogger, String) |
Logs a message with the trace log level. |
| LogTraceAsync(ILogger, String) |
Logs a message with the trace log level. |
| LogWarning(ILogger, String) |
Logs a message with the warning log level. |
| LogWarningAsync(ILogger, String) |
Logs a message with the warning log level. |