共用方式為


ExceptionSummarizationServiceCollectionExtensions.AddExceptionSummarizer 方法

定義

多載

AddExceptionSummarizer(IServiceCollection)

將例外狀況摘要器註冊至相依性插入容器。

AddExceptionSummarizer(IServiceCollection, Action<IExceptionSummarizationBuilder>)

將例外狀況摘要器註冊至相依性插入容器。

AddExceptionSummarizer(IServiceCollection)

來源:
ExceptionSummarizationServiceCollectionExtensions.cs
來源:
ExceptionSummarizationServiceCollectionExtensions.cs

將例外狀況摘要器註冊至相依性插入容器。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddExceptionSummarizer(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddExceptionSummarizer (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);
static member AddExceptionSummarizer : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddExceptionSummarizer (services As IServiceCollection) As IServiceCollection

參數

services
IServiceCollection

要加入摘要器的相依性插入容器。

傳回

services 的值。

例外狀況

servicesnull

適用於

AddExceptionSummarizer(IServiceCollection, Action<IExceptionSummarizationBuilder>)

來源:
ExceptionSummarizationServiceCollectionExtensions.cs
來源:
ExceptionSummarizationServiceCollectionExtensions.cs

將例外狀況摘要器註冊至相依性插入容器。

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddExceptionSummarizer(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Action<Microsoft::Extensions::Diagnostics::ExceptionSummarization::IExceptionSummarizationBuilder ^> ^ configure);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddExceptionSummarizer (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.Extensions.Diagnostics.ExceptionSummarization.IExceptionSummarizationBuilder> configure);
static member AddExceptionSummarizer : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.Extensions.Diagnostics.ExceptionSummarization.IExceptionSummarizationBuilder> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddExceptionSummarizer (services As IServiceCollection, configure As Action(Of IExceptionSummarizationBuilder)) As IServiceCollection

參數

services
IServiceCollection

要加入摘要器的相依性插入容器。

configure
Action<IExceptionSummarizationBuilder>

設定已註冊摘要提供者集的委派。

傳回

services 的值。

例外狀況

servicesconfigurenull

適用於