Table of Contents

Class Job

Namespace
Dynamicweb.DataIntegration.Integration
Assembly
Dynamicweb.DataIntegration.dll

This class describes one data transfer job. It can be saved to disk, reloaded and run again, assuming the schema of the source and the destination hasn't changed.

public class Job
Inheritance
Job
Inherited Members

Constructors

Job()

Initializes a new instance of the Job class.

public Job()

Job(ISource, IDestination)

Initializes an empty job

public Job(ISource source, IDestination destination)

Parameters

source ISource

data source

destination IDestination

data destination

Job(string, string)

Initializes a job from an XML Document

public Job(string path, string logFile)

Parameters

path string

uri to the XML document.

logFile string

path of logfile

Fields

AsTransaction

Indicates if, if possible, the job should be run as a transaction. Mostly relevant when the destination is an SQL server. Can only be changed by editing the saved XML job.

public bool AsTransaction

Field Value

bool

ConfigurationJobFolderName

public static readonly string ConfigurationJobFolderName

Field Value

string

CreateMappingAtRuntime

Indicates if column mappings should be created automatically at runtime, for the mappings added to the job.

public bool CreateMappingAtRuntime

Field Value

bool

Description

public string Description

Field Value

string

Name

Name of the job. The name of the XML file the job is saved to/loaded from.

public string Name

Field Value

string

Result

public volatile JobResult Result

Field Value

JobResult

ServiceCacheSettings

public ServiceCacheSettings ServiceCacheSettings

Field Value

ServiceCacheSettings

Properties

Culture

Formatting culture

public string Culture { get; set; }

Property Value

string

Destination

Gets or sets the destination of the job.

public virtual IDestination Destination { get; set; }

Property Value

IDestination

The destination.

DestinationProviderLabel

public string DestinationProviderLabel { get; }

Property Value

string

DisableCacheClearingAndIndexUpdates

Disable cache clearing and index update when there are no records changes at import.

public bool DisableCacheClearingAndIndexUpdates { get; set; }

Property Value

bool

Group

public string Group { get; set; }

Property Value

string

Id

public string Id { get; }

Property Value

string

IsResponseMappingSupported

public bool IsResponseMappingSupported { get; }

Property Value

bool

LastExecutionRunTime

public TimeSpan? LastExecutionRunTime { get; }

Property Value

TimeSpan?

LastRun

public DateTime? LastRun { get; }

Property Value

DateTime?

LastRunResult

public JobResult LastRunResult { get; }

Property Value

JobResult

LastSuccessfulRun

public DateTime? LastSuccessfulRun { get; }

Property Value

DateTime?

LogFileFullPath

public string LogFileFullPath { get; }

Property Value

string

LogFileRelativePath

public string LogFileRelativePath { get; }

Property Value

string

Logger

Logger

public ILogger Logger { get; }

Property Value

ILogger

MappingErrors

List of mapping errors

public List<SchemaComparerResult> MappingErrors { get; }

Property Value

List<SchemaComparerResult>

MappingType

MappingType

public MappingType MappingType { get; }

Property Value

MappingType

Mappings

Gets or sets the mapping collection.

public virtual MappingCollection Mappings { get; set; }

Property Value

MappingCollection

The mapping collection.

NotificationSettings

Notification settings

public NotificationSettings NotificationSettings { get; set; }

Property Value

NotificationSettings

RepositoriesIndexSettings

public RepositoriesIndexSettings RepositoriesIndexSettings { get; set; }

Property Value

RepositoriesIndexSettings

Source

Gets the source.

public virtual ISource Source { get; set; }

Property Value

ISource

SourceProviderLabel

public string SourceProviderLabel { get; }

Property Value

string

Methods

AddMapping()

Adds a table mapping to the job. The new table mapping is returned. The mapping is empty, so sourceTable and destinationTable should be set.

public Mapping AddMapping()

Returns

Mapping

Mapping object instance

CreateMappings()

Runs through the mappings in the job, and creates column mappings where the names of source columns match the name of a column in the destination column.

public void CreateMappings()

Delete()

public void Delete()

GetAdapters()

Gets job adapters

public List<AdapterBase> GetAdapters()

Returns

List<AdapterBase>

GetJob(string, bool)

public static Job GetJob(string jobName, bool dataImport)

Parameters

jobName string
dataImport bool

Returns

Job

GetJobFile(string)

public static FileInfo GetJobFile(string jobName)

Parameters

jobName string

Returns

FileInfo

GetJobFiles(bool)

public static List<FileInfo> GetJobFiles(bool getSorted = false)

Parameters

getSorted bool

Returns

List<FileInfo>

GetJobFiles(bool, bool)

public static List<FileInfo> GetJobFiles(bool getSorted, bool getAll)

Parameters

getSorted bool
getAll bool

Returns

List<FileInfo>

GetJobFolderFromIdentifier(string)

public static string GetJobFolderFromIdentifier(string jobIdentifier)

Parameters

jobIdentifier string

Returns

string

GetJobFolderName(string)

public static string GetJobFolderName(string jobFilePath)

Parameters

jobFilePath string

Returns

string

GetJobIdentifier(FileInfo)

public static string GetJobIdentifier(FileInfo jobFile)

Parameters

jobFile FileInfo

Returns

string

GetJobIdentifier(string, string)

public static string GetJobIdentifier(string folder, string jobName)

Parameters

folder string
jobName string

Returns

string

GetJobInformation(string, string)

Gets the job name and description from job XML Document

public static Job GetJobInformation(string path, string logFile)

Parameters

path string

uri to the XML document.

logFile string

path of logfile

Returns

Job

GetJobName(FileInfo)

public static string GetJobName(FileInfo jobFile)

Parameters

jobFile FileInfo

Returns

string

GetJobNameFromIdentifier(string)

public static string GetJobNameFromIdentifier(string jobIdentifier)

Parameters

jobIdentifier string

Returns

string

GetJobNewLogFile(string)

public static string GetJobNewLogFile(string jobName)

Parameters

jobName string

Returns

string

GetJobNewLogFile(string, string)

public static string GetJobNewLogFile(string jobName, string taskId)

Parameters

jobName string
taskId string

Returns

string

GetJobNewLogFile(string, string, string)

public static string GetJobNewLogFile(string jobName, string taskId, string timeStamp)

Parameters

jobName string
taskId string
timeStamp string

Returns

string

InitLogger(string)

public ILogger InitLogger(string fileName)

Parameters

fileName string

Returns

ILogger

IsDataImportJob(string)

public static bool IsDataImportJob(string jobName)

Parameters

jobName string

Returns

bool

IsSortable()

public bool IsSortable()

Returns

bool

Move(string, string)

public static void Move(string jobName, string groupName)

Parameters

jobName string
groupName string

Run()

Runs this job.

public bool Run()

Returns

bool

Save(bool)

public void Save(bool updateStatistic = false)

Parameters

updateStatistic bool

SaveAsXml(string)

Saves the job in an XML document

public void SaveAsXml(string savePath)

Parameters

savePath string

uri to save the document to

UpdateDestinationSetting(string, string)

Uses reflection to update a property on the source in this job.

public void UpdateDestinationSetting(string fieldName, string value)

Parameters

fieldName string

Name of the field.

value string

The value.

UpdateSourceSetting(string, string)

Uses reflection to update a property on the source in this job.

public void UpdateSourceSetting(string fieldName, string value)

Parameters

fieldName string

Name of the field.

value string

The value.

To top