Table of Contents

Class ImportExportOptions

Namespace
ArcanaDevelopment.adTempus.Shared
Assembly
ArcanaDevelopment.adTempus.Shared.dll

Specifies options for export and importing data.

[Serializable]
[DataContract]
public abstract class ImportExportOptions
Inheritance
object
ImportExportOptions
Derived

Constructors

ImportExportOptions()

public ImportExportOptions()

Fields

EncryptionKey

The encryption key to use to encrypt/decrypt passwords in the export file.

[DataMember]
public string EncryptionKey

Field Value

string

Remarks

If the IncludePasswords option is True on export, passwords are included in the export file but are encrypted. The EncryptionType specifies the method used for encryption.

  • If EncryptionType is ExportEncryptionType.DefaultKey, no EncryptionKey should be set. adTempus uses the default adTempus encryption key.
  • If EncryptionType is ExportEncryptionType.Password, EncryptionKey should be set to a password that will be used to encrypt/decrypt the data.
  • If EncryptionType is ExportEncryptionType.Asymmetric,

    • On export, EncryptionKey should be set to an RSA public key, which adTempus will use to encrypt the data.
    • On import, EncryptionKey should be set to the corresponding RSA private key.

Use RSACryptoServiceProvider to generate the key pair for asymmetric encryption.

Use SetPassword(string) to set the password for ExportEncryptionType.Password.

EncryptionType

Specifies the encryption type to use if passwords are included in the file.

[DataMember]
public ExportEncryptionType EncryptionType

Field Value

ExportEncryptionType

Remarks

See EncryptionKey for further information.

IncludeJobHistory

Include the job history (status, instances, and log messages) when exporting or importing a job. This option must be set for both the export and the import.

[DataMember]
public bool IncludeJobHistory

Field Value

bool

Properties

AdditionalOptions

Additional named options controlling the operation

[DataMember]
public Dictionary<string, object> AdditionalOptions { get; }

Property Value

Dictionary<string, object>

Methods

GetAdditionalOption<T>(string, T)

Gets the additional option with the specified name

public T GetAdditionalOption<T>(string optionName, T defaultValue)

Parameters

NameTypeDescription
optionName string

Case-insensitive name of the option to get

defaultValue T

The default value to return if the option is not defined

Returns

T

Type Parameters

NameDescription
T

SetPassword(string)

Sets the password to use when EncryptionType is ExportEncryptionType.Password

public void SetPassword(string source)

Parameters

NameTypeDescription
source string

Remarks

This method hashes the source value; the hash is then used as the password.