Interface ILogger
Defines an interface for the loggers to be used with the framework.
Namespace: Juhta.Net.Diagnostics
Assembly: Juhta.Net.dll
Syntax
public interface ILogger
Properties
| Improve this Doc View SourceIsThreadSafe
Returns true if this ILogger instance is thread-safe, otherwise false.
Declaration
bool IsThreadSafe { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceLogAlert(AlertMessage)
Logs an alert event.
Declaration
void LogAlert(AlertMessage message)
Parameters
Type | Name | Description |
---|---|---|
AlertMessage | message | Specifies an AlertMessage object. |
LogAlert(AlertMessage, Object[])
Logs an alert event.
Declaration
void LogAlert(AlertMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
AlertMessage | message | Specifies an AlertMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogAlert(String)
Logs an alert event.
Declaration
void LogAlert(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Specifies an alert message. |
LogAlert(String, Object[])
Logs an alert event.
Declaration
void LogAlert(string messageFormat, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.String | messageFormat | Specifies an alert message format containing zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in |
LogError(ErrorMessage)
Logs an error event.
Declaration
void LogError(ErrorMessage message)
Parameters
Type | Name | Description |
---|---|---|
ErrorMessage | message | Specifies an ErrorMessage object. |
LogError(ErrorMessage, Object[])
Logs an error event.
Declaration
void LogError(ErrorMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
ErrorMessage | message | Specifies an ErrorMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogError(Exception)
Logs an error event.
Declaration
void LogError(Exception exception)
Parameters
Type | Name | Description |
---|---|---|
System.Exception | exception | Specifies an Exception object whose string representation determines the error message. |
LogError(Exception, ErrorMessage)
Logs an error event consisting of an error message and exception.
Declaration
void LogError(Exception exception, ErrorMessage message)
Parameters
Type | Name | Description |
---|---|---|
System.Exception | exception | Specifies an Exception object. |
ErrorMessage | message | Specifies an ErrorMessage object. |
LogError(Exception, ErrorMessage, Object[])
Logs an error event consisting of an error message and exception.
Declaration
void LogError(Exception exception, ErrorMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.Exception | exception | Specifies an Exception object. |
ErrorMessage | message | Specifies an ErrorMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogError(Exception, String)
Logs an error event consisting of an error message and exception.
Declaration
void LogError(Exception exception, string message)
Parameters
Type | Name | Description |
---|---|---|
System.Exception | exception | Specifies an Exception object. |
System.String | message | Specifies an error message. |
LogError(Exception, String, Object[])
Logs an error event consisting of an error message and exception.
Declaration
void LogError(Exception exception, string messageFormat, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.Exception | exception | Specifies an Exception object. |
System.String | messageFormat | Specifies an error message format containing zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in |
LogError(String)
Logs an error event.
Declaration
void LogError(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Specifies an error message. |
LogError(String, Object[])
Logs an error event.
Declaration
void LogError(string messageFormat, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.String | messageFormat | Specifies an error message format containing zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in |
LogEvent(DiagnosticMessage)
Logs a diagnostic event.
Declaration
void LogEvent(DiagnosticMessage message)
Parameters
Type | Name | Description |
---|---|---|
DiagnosticMessage | message | Specifies a DiagnosticMessage object. |
LogEvent(DiagnosticMessage, Object[])
Logs a diagnostic event.
Declaration
void LogEvent(DiagnosticMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
DiagnosticMessage | message | Specifies a DiagnosticMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogInformation(InformationMessage)
Logs an information event.
Declaration
void LogInformation(InformationMessage message)
Parameters
Type | Name | Description |
---|---|---|
InformationMessage | message | Specifies an InformationMessage object. |
LogInformation(InformationMessage, Object[])
Logs an information event.
Declaration
void LogInformation(InformationMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
InformationMessage | message | Specifies an InformationMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogInformation(String)
Logs an information event.
Declaration
void LogInformation(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Specifies an information message. |
LogInformation(String, Object[])
Logs an information event.
Declaration
void LogInformation(string messageFormat, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.String | messageFormat | Specifies an information message format containing zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in |
LogWarning(WarningMessage)
Logs a warning event.
Declaration
void LogWarning(WarningMessage message)
Parameters
Type | Name | Description |
---|---|---|
WarningMessage | message | Specifies a WarningMessage object. |
LogWarning(WarningMessage, Object[])
Logs a warning event.
Declaration
void LogWarning(WarningMessage message, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
WarningMessage | message | Specifies a WarningMessage object whose Message property contains zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in the Message property of |
LogWarning(String)
Logs a warning event.
Declaration
void LogWarning(string message)
Parameters
Type | Name | Description |
---|---|---|
System.String | message | Specifies a warning message. |
LogWarning(String, Object[])
Logs a warning event.
Declaration
void LogWarning(string messageFormat, params object[] args)
Parameters
Type | Name | Description |
---|---|---|
System.String | messageFormat | Specifies a warning message format containing zero or more format items. |
System.Object[] | args | Specifies an object array containing zero or more objects to format. These objects must
correspond to the format items in |