Class CallbackAuthenticationTypeDomainMapping
AuthenticationTypeDomainMapping implementation that wraps a callback function.
Implements
Inherited Members
Namespace: Tableau.Migration.Engine.Hooks.Mappings.Default
Assembly: Tableau.Migration.dll
Syntax
public class CallbackAuthenticationTypeDomainMapping : AuthenticationTypeDomainMappingBase, IAuthenticationTypeDomainMapping, IContentMapping<IUser>, IMigrationHook<ContentMappingContext<IUser>>, IContentMapping<IGroup>, IMigrationHook<ContentMappingContext<IGroup>>
Constructors
CallbackAuthenticationTypeDomainMapping(Func<ContentMappingContext<IUsernameContent>, CancellationToken, Task<string?>>, ISharedResourcesLocalizer, ILogger<CallbackAuthenticationTypeDomainMapping>?)
Creates a new CallbackAuthenticationTypeDomainMapping object.
Declaration
public CallbackAuthenticationTypeDomainMapping(Func<ContentMappingContext<IUsernameContent>, CancellationToken, Task<string?>> callback, ISharedResourcesLocalizer localizer, ILogger<CallbackAuthenticationTypeDomainMapping>? logger)
Parameters
| Type | Name | Description |
|---|---|---|
| Func<ContentMappingContext<IUsernameContent>, CancellationToken, Task<string>> | callback | The callback to invoke. |
| ISharedResourcesLocalizer | localizer | A string localizer. |
| ILogger<CallbackAuthenticationTypeDomainMapping> | logger | Default logger. |
Methods
ExecuteAsync<T>(ContentMappingContext<T>, CancellationToken)
Executes the mapping for a user or group.
Declaration
protected override Task<ContentMappingContext<T>?> ExecuteAsync<T>(ContentMappingContext<T> context, CancellationToken cancel) where T : IUsernameContent
Parameters
| Type | Name | Description |
|---|---|---|
| ContentMappingContext<T> | context | The mapping context. |
| CancellationToken | cancel | The cancellation token to obey. |
Returns
| Type | Description |
|---|---|
| Task<ContentMappingContext<T>> | The mapped context. |
Type Parameters
| Name | Description |
|---|---|
| T | The IUsernameContent type. |