C# Class TaskMaster, TabMigrate

Mostra file Open project: tableau/TabMigrate Class Usage Examples

Public Properties

Property Type Description
JobName string

Private Properties

Property Type Description
AttemptExecutionOfCustomHttpGet void
ExecuteTask_Internal void
ExecuteTask_InternalAllTasks void
Execute_CreateProjectWithName void
Execute_DeleteTagFromDatasources void
Execute_DeleteTagFromWorkbooks void
Execute_DownloadDatasourceConnections void
Execute_DownloadDatasources void
Execute_DownloadDatasourcesList void
Execute_DownloadGroupsList DownloadGroupsList,
Execute_DownloadProjectsList DownloadProjectsList,
Execute_DownloadSiteInfo SiteinfoSite,
Execute_DownloadSiteUsers IEnumerable
Execute_DownloadWorkbooks void
Execute_DownloadWorkbooksConnections void
Execute_DownloadWorkbooksList void
Execute_GenerateManualStepsFile void
Execute_GenerateSiteInventoryFile void
Execute_GenerateSiteInventoryFile_Twb void
Execute_LoadDBCredentialsFile CredentialManager,
Execute_SaveErrorsFile void
Execute_SaveLogFile void
Execute_UploadDatasources void
Execute_UploadWorkbooks void
helper_AddValueIfExists void
helper_CreateTaskMaster_SiteExport TaskMaster,
helper_CreateTaskMaster_SiteImport TaskMaster,
helper_CreateTaskMaster_SiteInventory TaskMaster,
helper_DetermineIfSingleProjectFilter SiteProject,

Public Methods

Method Description
Abort ( bool markAsDone = false ) : void

Called to force an abort

ExecuteTaskBegin ( ) : void

Starts the task running

FromCommandLine ( CommandLineParser, commandLine ) : TaskMaster,

Creates a TaskMaster from command line arguments

IsValidImportFromDirectory ( string path ) : bool

Returns TRUE if the specified directory looks to be a valid directory we can import site content from

TaskMaster ( string jobName, TableauServerUrls, onlineUrls, string userName, string password, TaskMasterOptions, taskOptions, CustomerManualActionManager manualActions = null ) : System

Constructor

Private Methods

Method Description
AttemptExecutionOfCustomHttpGet ( TableauServerSignIn, onlineLogin, string customCommand ) : void

Called to attempt to execute a custom command (to be run after the user logs in)

ExecuteTask_Internal ( ) : void

Called when the background thread is run

ExecuteTask_InternalAllTasks ( ) : void

Perform the work

Execute_CreateProjectWithName ( TableauServerSignIn, onlineLogin, string projectName ) : void

Attempts to create a project

Execute_DeleteTagFromDatasources ( TableauServerSignIn, onlineLogin, ICollection contentSet, string removeTag ) : void

Attempt to remove a tag from a set of datasources

Execute_DeleteTagFromWorkbooks ( TableauServerSignIn, onlineLogin, ICollection contentSet, string removeTag ) : void

Attempt to remove a tag from a set of workbooks

Execute_DownloadDatasourceConnections ( TableauServerSignIn, serverLogin, IEnumerable serverContent ) : void

Downloads the connections list for each datasource specified

Execute_DownloadDatasources ( TableauServerSignIn, onlineLogin, string exportToPath, IProjectsList projectsList, SiteProject, singleProjectIdFilter = null, string exportOnlyWithThisTag = null, bool deleteTagAfterExport = false, bool generateInfoFile = false, IEnumerable siteUsers = null ) : void

Execute_DownloadDatasourcesList ( TableauServerSignIn, onlineLogin ) : void

Download the data sources

Execute_DownloadGroupsList ( TableauServerSignIn, onlineLogin ) : DownloadGroupsList,

Downloads the set of groups in the site

Execute_DownloadProjectsList ( TableauServerSignIn, onlineLogin ) : DownloadProjectsList,

Downloads the set of projects in the site

Execute_DownloadSiteInfo ( TableauServerSignIn, onlineLogin ) : SiteinfoSite,

Execute_DownloadSiteUsers ( TableauServerSignIn, onlineLogin ) : IEnumerable

Download the users in the site

Execute_DownloadWorkbooks ( TableauServerSignIn, onlineLogin, string exportToPath, IProjectsList projectsList, SiteProject, singleProjectIdFilter = null, string exportOnlyWithThisTag = null, bool deleteTagAfterExport = false, bool generateInfoFile = false, IEnumerable siteUsers = null ) : void

Download the workbooks

Execute_DownloadWorkbooksConnections ( TableauServerSignIn, serverLogin, IEnumerable serverContent ) : void

Downloads the connections list for each workbook specified

Execute_DownloadWorkbooksList ( TableauServerSignIn, onlineLogin ) : void

Download the data sources

Execute_GenerateManualStepsFile ( string filename ) : void

Save the log file

Execute_GenerateSiteInventoryFile ( string pathReport ) : void

Generate the status report of the site's inventory

Execute_GenerateSiteInventoryFile_Twb ( string pathReportCsv ) : void

Creates a TWB file that points to the CSV file

Execute_LoadDBCredentialsFile ( string pathDBCredentials ) : CredentialManager,

Attempts to load a DB credential file

Execute_SaveErrorsFile ( string filename ) : void

Save the errors file

Execute_SaveLogFile ( string logFile ) : void

Save the log file

Execute_UploadDatasources ( TableauServerSignIn, onlineLogin, string localBasePath, CredentialManager, credentialManager, bool attemptContentOwnershipAssignment, IEnumerable siteUsers ) : void

Called to perform Uploads of the data sources

Execute_UploadWorkbooks ( TableauServerSignIn, onlineLogin, string localBasePath, bool remapWorkbookReferences, CredentialManager, credentialManager, bool attemptContentOwnershipAssignment, IEnumerable siteUsers ) : void

Called to perform Uploads of the workbooks

helper_AddValueIfExists ( TaskMasterOptions, options, string optionKey, CommandLineParser, commandLine, string commandLineKey ) : void

Helper: Adds a command line parameter (if it exists) to the Options colleciton

helper_CreateTaskMaster_SiteExport ( string dirExportDirectory, string urlToServerSite, string userName, string password, bool isSiteAdmin, string exportSingleProject, string exportOnlyTaggedWith, bool removeTagAfterExport, bool generateInfoFilesForDownloadedContent, TaskMasterOptions, options ) : TaskMaster,

Sets up parameters needed by Site Export

helper_CreateTaskMaster_SiteImport ( string dirImportFromDirectory, string urlToServerSite, string userName, string password, bool isSiteAdmin, bool remapDataserverReferences, string pathDbCredentials, bool assignContentOwnership, TaskMasterOptions, options ) : TaskMaster,

Sets up parameters needed by Site Import

helper_CreateTaskMaster_SiteInventory ( string pathToWriteInventoryFile, string urlToServerSite, string userName, string password, bool isSystemAdmin, bool generateTwbFile, TaskMasterOptions, options ) : TaskMaster,

Sets up parameters needed by site inventory

helper_DetermineIfSingleProjectFilter ( IProjectsList projectsList ) : SiteProject,

If the user has specified a single project filter, then get it from the projects list

Method Details

Abort() public method

Called to force an abort
public Abort ( bool markAsDone = false ) : void
markAsDone bool
return void

ExecuteTaskBegin() public method

Starts the task running
public ExecuteTaskBegin ( ) : void
return void

FromCommandLine() public static method

Creates a TaskMaster from command line arguments
public static FromCommandLine ( CommandLineParser, commandLine ) : TaskMaster,
commandLine CommandLineParser,
return TaskMaster,

IsValidImportFromDirectory() public static method

Returns TRUE if the specified directory looks to be a valid directory we can import site content from
public static IsValidImportFromDirectory ( string path ) : bool
path string
return bool

TaskMaster() public method

Constructor
public TaskMaster ( string jobName, TableauServerUrls, onlineUrls, string userName, string password, TaskMasterOptions, taskOptions, CustomerManualActionManager manualActions = null ) : System
jobName string Name to associate with this work
onlineUrls TableauServerUrls,
userName string
password string
taskOptions TaskMasterOptions,
manualActions CustomerManualActionManager
return System

Property Details

JobName public_oe property

public string JobName
return string