LoggerMessageAttribute Constructors
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.
Overloads
LoggerMessageAttribute() |
Initializes a new instance of the LoggerMessageAttribute class which is used to guide the production of a strongly-typed logging method. |
LoggerMessageAttribute(LogLevel) |
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method. |
LoggerMessageAttribute(String) |
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method. |
LoggerMessageAttribute(LogLevel, String) |
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method. |
LoggerMessageAttribute(Int32, LogLevel, String) |
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method. |
LoggerMessageAttribute()
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
Initializes a new instance of the LoggerMessageAttribute class which is used to guide the production of a strongly-typed logging method.
public:
LoggerMessageAttribute();
public LoggerMessageAttribute ();
Public Sub New ()
Applies to
LoggerMessageAttribute(LogLevel)
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method.
public:
LoggerMessageAttribute(Microsoft::Extensions::Logging::LogLevel level);
public LoggerMessageAttribute (Microsoft.Extensions.Logging.LogLevel level);
new Microsoft.Extensions.Logging.LoggerMessageAttribute : Microsoft.Extensions.Logging.LogLevel -> Microsoft.Extensions.Logging.LoggerMessageAttribute
Public Sub New (level As LogLevel)
Parameters
- level
- LogLevel
The log level.
Applies to
LoggerMessageAttribute(String)
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method.
public:
LoggerMessageAttribute(System::String ^ message);
public LoggerMessageAttribute (string message);
new Microsoft.Extensions.Logging.LoggerMessageAttribute : string -> Microsoft.Extensions.Logging.LoggerMessageAttribute
Public Sub New (message As String)
Parameters
- message
- String
The format string of the log message.
Applies to
LoggerMessageAttribute(LogLevel, String)
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method.
public:
LoggerMessageAttribute(Microsoft::Extensions::Logging::LogLevel level, System::String ^ message);
public LoggerMessageAttribute (Microsoft.Extensions.Logging.LogLevel level, string message);
new Microsoft.Extensions.Logging.LoggerMessageAttribute : Microsoft.Extensions.Logging.LogLevel * string -> Microsoft.Extensions.Logging.LoggerMessageAttribute
Public Sub New (level As LogLevel, message As String)
Parameters
- level
- LogLevel
The log level.
- message
- String
The format string of the log message.
Applies to
LoggerMessageAttribute(Int32, LogLevel, String)
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
- Source:
- LoggerMessageAttribute.cs
Initializes a new instance of the LoggerMessageAttribute class, which is used to guide the production of a strongly typed logging method.
public:
LoggerMessageAttribute(int eventId, Microsoft::Extensions::Logging::LogLevel level, System::String ^ message);
public LoggerMessageAttribute (int eventId, Microsoft.Extensions.Logging.LogLevel level, string message);
new Microsoft.Extensions.Logging.LoggerMessageAttribute : int * Microsoft.Extensions.Logging.LogLevel * string -> Microsoft.Extensions.Logging.LoggerMessageAttribute
Public Sub New (eventId As Integer, level As LogLevel, message As String)
Parameters
- eventId
- Int32
The log event ID.
- level
- LogLevel
The log level.
- message
- String
The format string of the log message.
Applies to
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈