Class WorkbookReferenceTransformer<TContent>
Transformer that changes the workbook reference for a content item. It sets the workbook reference to that of the destination.
Inherited Members
Namespace: Tableau.Migration.Engine.Hooks.Transformers.Default
Assembly: Tableau.Migration.dll
Syntax
public class WorkbookReferenceTransformer<TContent> : ContentTransformerBase<TContent>, IContentTransformer<TContent>, IMigrationHook<TContent> where TContent : IWithWorkbook
Type Parameters
Name | Description |
---|---|
TContent |
Constructors
WorkbookReferenceTransformer(IDestinationContentReferenceFinderFactory, ILogger<WorkbookReferenceTransformer<TContent>>, ISharedResourcesLocalizer)
Creates a new WorkbookReferenceTransformer<TContent> object.
Declaration
public WorkbookReferenceTransformer(IDestinationContentReferenceFinderFactory destinationFinderFactory, ILogger<WorkbookReferenceTransformer<TContent>> logger, ISharedResourcesLocalizer localizer)
Parameters
Type | Name | Description |
---|---|---|
IDestinationContentReferenceFinderFactory | destinationFinderFactory | The destination finder factory. |
ILogger<WorkbookReferenceTransformer<TContent>> | logger | The logger used to log messages. |
ISharedResourcesLocalizer | localizer | The string localizer. |
Methods
TransformAsync(TContent, CancellationToken)
Executes the transformation.
Declaration
public override Task<TContent?> TransformAsync(TContent ctx, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
TContent | ctx | |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<TContent> | A task to await containing the context,
potentially modified to pass on to the next hook or migration engine,
or null to continue passing the same context as |