共用方式為


FakeRedactionServiceCollectionExtensions.AddFakeRedaction 方法

定義

多載

AddFakeRedaction(IServiceCollection)

註冊一律會傳回假的 Redactor 實例的假 Redactor 提供者。

AddFakeRedaction(IServiceCollection, Action<FakeRedactorOptions>)

註冊一律會傳回假的 Redactor 實例的假 Redactor 提供者。

AddFakeRedaction(IServiceCollection)

來源:
FakeRedactionServiceCollectionExtensions.cs
來源:
FakeRedactionServiceCollectionExtensions.cs

註冊一律會傳回假的 Redactor 實例的假 Redactor 提供者。

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

參數

services
IServiceCollection

用來註冊假修訂類別的容器。

傳回

services 的值。

例外狀況

servicesnull

適用於

AddFakeRedaction(IServiceCollection, Action<FakeRedactorOptions>)

來源:
FakeRedactionServiceCollectionExtensions.cs
來源:
FakeRedactionServiceCollectionExtensions.cs

註冊一律會傳回假的 Redactor 實例的假 Redactor 提供者。

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

參數

services
IServiceCollection

用來註冊假修訂類別的容器。

configure
Action<FakeRedactorOptions>

設定假的重做函式。

傳回

services 的值。

例外狀況

servicesconfigure> 為 null

適用於