Class TableauApiDestinationEndpoint
IDestinationEndpoint implementation that uses Tableau Server/Cloud APIs.
Implements
Inherited Members
Namespace: Tableau.Migration.Engine.Endpoints
Assembly: Tableau.Migration.dll
Syntax
public class TableauApiDestinationEndpoint : TableauApiEndpointBase, IDestinationApiEndpoint, IDestinationEndpoint, IMigrationApiEndpoint, IMigrationEndpoint, IAsyncDisposable
Constructors
TableauApiDestinationEndpoint(IServiceScopeFactory, ITableauApiEndpointConfiguration, IDestinationContentReferenceFinderFactory, IContentFileStore, ISharedResourcesLocalizer)
Creates a new TableauApiDestinationEndpoint object.
Declaration
public TableauApiDestinationEndpoint(IServiceScopeFactory serviceScopeFactory, ITableauApiEndpointConfiguration config, IDestinationContentReferenceFinderFactory finderFactory, IContentFileStore fileStore, ISharedResourcesLocalizer localizer)
Parameters
Type | Name | Description |
---|---|---|
IServiceScopeFactory | serviceScopeFactory | A service scope factory to define an API client scope with. |
ITableauApiEndpointConfiguration | config | The configuration options for connecting to the destination endpoint APIs. |
IDestinationContentReferenceFinderFactory | finderFactory | A destination finder factory. |
IContentFileStore | fileStore | The file store to use. |
ISharedResourcesLocalizer | localizer | A string localizer. |
Methods
PublishAsync<TPublish, TPublishResult>(TPublish, CancellationToken)
Publishes a content item.
Declaration
public Task<IResult<TPublishResult>> PublishAsync<TPublish, TPublishResult>(TPublish publishItem, CancellationToken cancel) where TPublishResult : class, IContentReference
Parameters
Type | Name | Description |
---|---|---|
TPublish | publishItem | The content item to publish. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<TPublishResult>> | The results of the publishing with a content reference of the newly published item. |
Type Parameters
Name | Description |
---|---|
TPublish | The content type suitable for publishing. |
TPublishResult | The publish result type. |
PublishBatchAsync<TPublish>(IEnumerable<TPublish>, CancellationToken)
Publishes a batch of content items.
Declaration
public Task<IResult> PublishBatchAsync<TPublish>(IEnumerable<TPublish> publishItems, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<TPublish> | publishItems | The content items to publish. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult> | The results of the publishing. |
Type Parameters
Name | Description |
---|---|
TPublish | The content type suitable for publishing. |
SetCustomViewDefaultUsersAsync(Guid, IEnumerable<IContentReference>, CancellationToken)
Update the custom view's default users.
Declaration
public Task<IResult<IImmutableList<ICustomViewAsUserDefaultViewResult>>> SetCustomViewDefaultUsersAsync(Guid id, IEnumerable<IContentReference> users, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
Guid | id | The ID of the custom view. |
IEnumerable<IContentReference> | users | The list of users who have the custom view as their default. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<IImmutableList<ICustomViewAsUserDefaultViewResult>>> | The result of the default user list update. |
UpdateConnectionAsync<TContent>(Guid, Guid, IUpdateConnectionOptions, CancellationToken)
Update the connection on the data source.
Declaration
public Task<IResult<IConnection>> UpdateConnectionAsync<TContent>(Guid contentItemId, Guid connectionId, IUpdateConnectionOptions options, CancellationToken cancel) where TContent : IWithConnections
Parameters
Type | Name | Description |
---|---|---|
Guid | contentItemId | The ID of the content item to update connections for. |
Guid | connectionId | The ID of the connection to be updated. |
IUpdateConnectionOptions | options | The update connetion options. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<IConnection>> | The result of the connection update operation. |
Type Parameters
Name | Description |
---|---|
TContent |
UpdateOwnerAsync<TContent>(IContentReference, IContentReference, CancellationToken)
Updates the owner for the content item.
Declaration
public Task<IResult> UpdateOwnerAsync<TContent>(IContentReference contentItem, IContentReference owner, CancellationToken cancel) where TContent : IWithOwner
Parameters
Type | Name | Description |
---|---|---|
IContentReference | contentItem | The content item to update ownership for. |
IContentReference | owner | The new owner. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult> | The result of the owner update operation. |
Type Parameters
Name | Description |
---|---|
TContent | The content type. |
UpdatePermissionsAsync(Type, IContentReference, IPermissions, CancellationToken)
Updates the permissions for the content item.
Declaration
public Task<IResult> UpdatePermissionsAsync(Type type, IContentReference contentItem, IPermissions permissions, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
Type | type | Type of content item |
IContentReference | contentItem | The content item. |
IPermissions | permissions | The permissions of the content item. |
CancellationToken | cancel | The cancellation token. |
Returns
Type | Description |
---|---|
Task<IResult> | The permissions result with IPermissions. |
UpdatePermissionsAsync<TContent>(IContentReference, IPermissions, CancellationToken)
Updates the permissions for the content item.
Declaration
public Task<IResult> UpdatePermissionsAsync<TContent>(IContentReference contentItem, IPermissions permissions, CancellationToken cancel) where TContent : IPermissionsContent
Parameters
Type | Name | Description |
---|---|---|
IContentReference | contentItem | The content item. |
IPermissions | permissions | The permissions of the content item. |
CancellationToken | cancel | The cancellation token. |
Returns
Type | Description |
---|---|
Task<IResult> | The permissions result with IPermissions. |
Type Parameters
Name | Description |
---|---|
TContent |
UpdateSiteSettingsAsync(ISiteSettingsUpdate, CancellationToken)
Update the settings of a site.
Declaration
public Task<IResult<ISite>> UpdateSiteSettingsAsync(ISiteSettingsUpdate newSiteSettings, CancellationToken cancel)
Parameters
Type | Name | Description |
---|---|---|
ISiteSettingsUpdate | newSiteSettings | The site settings to update. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult<ISite>> | The result of the site update operation. |
UpdateTagsAsync<TContent>(IContentReference, IEnumerable<ITag>, CancellationToken)
Updates the tags for the content item.
Declaration
public Task<IResult> UpdateTagsAsync<TContent>(IContentReference contentItem, IEnumerable<ITag> tags, CancellationToken cancel) where TContent : IWithTags
Parameters
Type | Name | Description |
---|---|---|
IContentReference | contentItem | The content item to update tags for. |
IEnumerable<ITag> | tags | The tags to apply. |
CancellationToken | cancel | The cancellation token to obey. |
Returns
Type | Description |
---|---|
Task<IResult> | The result of the tag update operation. |
Type Parameters
Name | Description |
---|---|
TContent | The content type. |