HostingHostBuilderExtensions.ConfigureLogging 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.
Overloads
ConfigureLogging(IHostBuilder, Action<HostBuilderContext,ILoggingBuilder>) |
Adds a delegate for configuring the provided ILoggingBuilder. This can be called multiple times. |
ConfigureLogging(IHostBuilder, Action<ILoggingBuilder>) |
Adds a delegate for configuring the provided ILoggingBuilder. This can be called multiple times. |
ConfigureLogging(IHostBuilder, Action<HostBuilderContext,ILoggingBuilder>)
Adds a delegate for configuring the provided ILoggingBuilder. This can be called multiple times.
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Hosting::IHostBuilder ^ ConfigureLogging(Microsoft::Extensions::Hosting::IHostBuilder ^ hostBuilder, Action<Microsoft::Extensions::Hosting::HostBuilderContext ^, Microsoft::Extensions::Logging::ILoggingBuilder ^> ^ configureLogging);
public static Microsoft.Extensions.Hosting.IHostBuilder ConfigureLogging (this Microsoft.Extensions.Hosting.IHostBuilder hostBuilder, Action<Microsoft.Extensions.Hosting.HostBuilderContext,Microsoft.Extensions.Logging.ILoggingBuilder> configureLogging);
static member ConfigureLogging : Microsoft.Extensions.Hosting.IHostBuilder * Action<Microsoft.Extensions.Hosting.HostBuilderContext, Microsoft.Extensions.Logging.ILoggingBuilder> -> Microsoft.Extensions.Hosting.IHostBuilder
<Extension()>
Public Function ConfigureLogging (hostBuilder As IHostBuilder, configureLogging As Action(Of HostBuilderContext, ILoggingBuilder)) As IHostBuilder
Parameters
- hostBuilder
- IHostBuilder
The IHostBuilder to configure.
- configureLogging
- Action<HostBuilderContext,ILoggingBuilder>
The delegate that configures the ILoggingBuilder.
Returns
The same instance of the IHostBuilder for chaining.
Applies to
ConfigureLogging(IHostBuilder, Action<ILoggingBuilder>)
Adds a delegate for configuring the provided ILoggingBuilder. This can be called multiple times.
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Hosting::IHostBuilder ^ ConfigureLogging(Microsoft::Extensions::Hosting::IHostBuilder ^ hostBuilder, Action<Microsoft::Extensions::Logging::ILoggingBuilder ^> ^ configureLogging);
public static Microsoft.Extensions.Hosting.IHostBuilder ConfigureLogging (this Microsoft.Extensions.Hosting.IHostBuilder hostBuilder, Action<Microsoft.Extensions.Logging.ILoggingBuilder> configureLogging);
static member ConfigureLogging : Microsoft.Extensions.Hosting.IHostBuilder * Action<Microsoft.Extensions.Logging.ILoggingBuilder> -> Microsoft.Extensions.Hosting.IHostBuilder
<Extension()>
Public Function ConfigureLogging (hostBuilder As IHostBuilder, configureLogging As Action(Of ILoggingBuilder)) As IHostBuilder
Parameters
- hostBuilder
- IHostBuilder
The IHostBuilder to configure.
- configureLogging
- Action<ILoggingBuilder>
The delegate that configures the ILoggingBuilder.
Returns
The same instance of the IHostBuilder for chaining.