London Dev Meetup Rescheduled! Due to unavoidable reasons, the event has been moved to 21st May. Speakers remain the same—any changes will be communicated. Seats are limited—register here to secure your spot!

Class ImportJob

Job for importing catalogs

Inheritance
System.Object
ImportJob
Implements
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Mediachase.Commerce.Catalog.ImportExport
Assembly: Mediachase.Commerce.dll
Version: 13.30.0
Syntax
public class ImportJob : IBackgroundTask

Constructors

ImportJob(IDictionary<String, String>)

Declaration
public ImportJob(IDictionary<string, string> arguments)
Parameters
Type Name Description
System.Collections.Generic.IDictionary<System.String, System.String> arguments

ImportJob(String, Boolean)

Initializes a new instance of the ImportJob class.

Declaration
public ImportJob(string sourceZipFile, bool overwriteDuplicates)
Parameters
Type Name Description
System.String sourceZipFile

The source zip file.

System.Boolean overwriteDuplicates

if set to true [overwrite duplicates].

ImportJob(String, String, Boolean)

Initializes a new instance of the ImportJob class.

Declaration
public ImportJob(string sourceZipFile, string sourceXmlInZip, bool overwriteDuplicates)
Parameters
Type Name Description
System.String sourceZipFile

The source zip file.

System.String sourceXmlInZip

The source XML in zip.

System.Boolean overwriteDuplicates

if set to true [overwrite duplicates].

ImportJob(String, String, Boolean, Boolean)

Initializes a new instance of the ImportJob class.

Declaration
public ImportJob(string sourceZipFile, string sourceXmlInZip, bool overwriteDuplicates, bool isModelsAvailable)
Parameters
Type Name Description
System.String sourceZipFile

The source zip file.

System.String sourceXmlInZip

The source XML in zip.

System.Boolean overwriteDuplicates

if set to true [overwrite duplicates].

System.Boolean isModelsAvailable

Determines of the strongly typed models are available to allow asset linking.
The default value is true.
Set to false if you are importing in commerce manager or another context where the media models are not available

Fields

DefaultXmlFileInZip

Declaration
public static readonly string DefaultXmlFileInZip
Field Value
Type Description
System.String

Properties

BackgroundTaskType

Declaration
public Type BackgroundTaskType { get; }
Property Value
Type Description
System.Type

TaskArguments

Declaration
public IDictionary<string, string> TaskArguments { get; }
Property Value
Type Description
System.Collections.Generic.IDictionary<System.String, System.String>

Methods

Execute(Action<IBackgroundTaskMessage>, CancellationToken)

Declaration
public bool Execute(Action<IBackgroundTaskMessage> addMessage, CancellationToken cancellationToken)
Parameters
Type Name Description
System.Action<IBackgroundTaskMessage> addMessage
System.Threading.CancellationToken cancellationToken
Returns
Type Description
System.Boolean

Implements