ILogger.Log<TState> Method
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.
Logs a message with the specified log level, state, exception, and formatter.
public void Log<TState>(Microsoft.Testing.Platform.Logging.LogLevel logLevel, TState state, Exception? exception, Func<TState,Exception?,string> formatter);
abstract member Log : Microsoft.Testing.Platform.Logging.LogLevel * 'State * Exception * Func<'State, Exception, string> -> unit
Public Sub Log(Of TState) (logLevel As LogLevel, state As TState, exception As Exception, formatter As Func(Of TState, Exception, String))
Type Parameters
- TState
The type of the state object.
Parameters
- logLevel
- LogLevel
The log level of the message.
- state
- TState
The state object.
- exception
- Exception
The exception associated with the message.