FakeRedactionServiceCollectionExtensions.AddFakeRedaction Method

Definition

Overloads

AddFakeRedaction(IServiceCollection)

Registers the fake redactor provider that always returns fake redactor instances.

AddFakeRedaction(IServiceCollection, Action<FakeRedactorOptions>)

Registers the fake redactor provider that always returns fake redactor instances.

AddFakeRedaction(IServiceCollection)

Source:
FakeRedactionServiceCollectionExtensions.cs

Registers the fake redactor provider that always returns fake redactor instances.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddFakeRedaction (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);

Parameters

services
IServiceCollection

Container used to register fake redaction classes.

Returns

The value of services.

Exceptions

services is null.

Applies to

.NET 9 (package-provided) and other versions
Product Versions
.NET 6 (package-provided), 8 (package-provided), 9 (package-provided)
.NET Framework 4.7 (package-provided), 4.7.1 (package-provided), 4.7.2 (package-provided), 4.8 (package-provided)

AddFakeRedaction(IServiceCollection, Action<FakeRedactorOptions>)

Source:
FakeRedactionServiceCollectionExtensions.cs

Registers the fake redactor provider that always returns fake redactor instances.

public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddFakeRedaction (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.Extensions.Compliance.Testing.FakeRedactorOptions> configure);

Parameters

services
IServiceCollection

Container used to register fake redaction classes.

configure
Action<FakeRedactorOptions>

Configures fake redactor.

Returns

The value of services.

Exceptions

services or configure> are null.

Applies to

.NET 9 (package-provided) and other versions
Product Versions
.NET 6 (package-provided), 8 (package-provided), 9 (package-provided)
.NET Framework 4.7 (package-provided), 4.7.1 (package-provided), 4.7.2 (package-provided), 4.8 (package-provided)