Interface ILogger
Provides an interface for logging messages with different log levels and message formatting options.
Namespace: Innovt.Core.CrossCutting.Log
Assembly: Innovt.Core.dll
Syntax
[CLSCompliant(true)]
public interface ILogger
Methods
| Edit this page View SourceDebug(Exception, string)
Debug is the noisiest level, rarely (if ever) enabled for a production app.
Declaration
void Debug(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | An Exception parameter |
string | messageTemplate | The message templete will follow the Serilog Pattern. |
Debug(Exception, string, params object[])
Debug is the noisiest level, rarely (if ever) enabled for a production app.
Declaration
void Debug(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | An exception |
string | messageTemplate | The message templete will follow the Serilog Pattern. |
object[] | propertyValues |
Debug(string)
Debug is the noisiest level, rarely (if ever) enabled for a production app.
Declaration
void Debug(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The message will follow the Serilog Pattern. |
Debug(string, params object[])
Debug is the noisiest level, rarely (if ever) enabled for a production app.
Declaration
void Debug(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The message templete will follow the Serilog Pattern. |
object[] | propertyValues | Properties that will be used as template of the message |
Error(Exception, string)
Logs an error message with an exception and a message template.
Declaration
void Error(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The error message template following the Serilog pattern. |
Error(Exception, string, params object[])
Logs an error message with an exception, a message template, and optional property values.
Declaration
void Error(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The error message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Error(string)
An error logger
Declaration
void Error(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The message templete will follow the Serilog Pattern. |
Error(string, params object[])
Logs an error message with a message template and optional property values.
Declaration
void Error(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The error message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Fatal(Exception, string)
Logs a fatal error message with an exception and a message template.
Declaration
void Fatal(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The fatal error message template following the Serilog pattern. |
Fatal(Exception, string, params object[])
Logs a fatal error message with an exception, a message template, and optional property values.
Declaration
void Fatal(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The fatal error message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Fatal(string)
Logs a fatal error message.
Declaration
void Fatal(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The fatal error message to log. |
Fatal(string, params object[])
Logs a fatal error message with a message template and optional property values.
Declaration
void Fatal(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The fatal error message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Info(Exception, string)
Logs an information message with an exception and a message template.
Declaration
void Info(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The information message template following the Serilog pattern. |
Info(Exception, string, params object[])
Logs an information message with an exception, a message template, and optional property values.
Declaration
void Info(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The information message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Info(string)
Logs an information message.
Declaration
void Info(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The information message to log. |
Info(string, params object[])
Logs an information message with a message template and optional property values.
Declaration
void Info(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The information message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Verbose(Exception, string)
Logs a verbose message with an exception and a message template.
Declaration
void Verbose(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The verbose message template following the Serilog pattern. |
Verbose(Exception, string, params object[])
Logs a verbose message with an exception, a message template, and optional property values.
Declaration
void Verbose(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The verbose message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Verbose(string)
Logs a verbose message.
Declaration
void Verbose(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The verbose message to log. |
Verbose(string, params object[])
Logs a verbose message with a message template and optional property values.
Declaration
void Verbose(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The verbose message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Warning(Exception, string)
Logs a warning message with an exception and a message template.
Declaration
void Warning(Exception exception, string messageTemplate)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The warning message template following the Serilog pattern. |
Warning(Exception, string, params object[])
Logs a warning message with an exception, a message template, and optional property values.
Declaration
void Warning(Exception exception, string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
Exception | exception | The exception to log. |
string | messageTemplate | The warning message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |
Warning(string)
Logs a warning message.
Declaration
void Warning(string message)
Parameters
Type | Name | Description |
---|---|---|
string | message | The warning message to log. |
Warning(string, params object[])
Logs a warning message with a message template and optional property values.
Declaration
void Warning(string messageTemplate, params object[] propertyValues)
Parameters
Type | Name | Description |
---|---|---|
string | messageTemplate | The warning message template following the Serilog pattern. |
object[] | propertyValues | Optional property values used in the message template. |