Class ImportSettings
Represents a group of settings which control the way the import is executed.
Inheritance
Inherited Members
Namespace: Sdl.LanguagePlatform.TranslationMemory
Assembly: Sdl.LanguagePlatform.TranslationMemory.dll
Syntax
public class ImportSettings
Constructors
ImportSettings()
Initializes a new instance with default values.
Declaration
public ImportSettings()
Fields
DefaultTagCountLimit
The default limit for the maximum number of tags a TU segment may contain.
Declaration
public static readonly int DefaultTagCountLimit
Field Value
| Type | Description |
|---|---|
| System.Int32 |
Properties
AcronymsAutoSubstitution
Gets or sets the TU Processing Mode to be applied to the import.
Declaration
[Obsolete("This flag is now ignored. If Acronym recognizer is enabled for a TM, Acronym auto-substitution will always be enabled during import (just like other recognizers).")]
public bool AcronymsAutoSubstitution { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
AlignmentQuality
Gets/Sets the minimum import alignment quality value(default value: 70)
Declaration
public int AlignmentQuality { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
CheckMatchingSublanguages
Gets or sets whether the import should enforce that the sublanguages match.
Declaration
public bool CheckMatchingSublanguages { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
ConfirmationLevels
Gets or sets the confirmation levels which TUs of a document import should have in order to be imported. When null or empty, all segments are imported. Note: TUs excluded by this also do not generate context for their neighbour(s) when the TM context type is PrecedingSourceAndTarget
Declaration
public ConfirmationLevel[] ConfirmationLevels { get; set; }
Property Value
| Type | Description |
|---|---|
| ConfirmationLevel[] |
EditScript
Allows to perform edits during import. The edit script will be applied after the filter is applied (if present), but before the project settings are applied.
Declaration
public EditScript EditScript { get; set; }
Property Value
| Type | Description |
|---|---|
| EditScript |
ExistingFieldsUpdateMode
Gets or sets the value indicating how to handle values of existing fields.
Declaration
public ImportSettings.FieldUpdateMode ExistingFieldsUpdateMode { get; set; }
Property Value
| Type | Description |
|---|---|
| ImportSettings.FieldUpdateMode |
ExistingTUsUpdateMode
Gets or sets the value indicating how to update TU when a TU with the same source segment already exists in the TM
Declaration
public ImportSettings.TUUpdateMode ExistingTUsUpdateMode { get; set; }
Property Value
| Type | Description |
|---|---|
| ImportSettings.TUUpdateMode |
FieldIdentifierMappings
Gets or sets the field identifier mappings; old field identifier, new field identifier. Field identifier mapping immediately maps the field identifier read to another field identifier.
Declaration
public IDictionary<FieldIdentifier, FieldIdentifier> FieldIdentifierMappings { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Collections.Generic.IDictionary<FieldIdentifier, FieldIdentifier> |
Filter
Allows to access a filter to be used during import. If a filter is set, only matching translation units will be imported. Note that filters will not be evaluated during document imports.
Declaration
public FilterExpression Filter { get; set; }
Property Value
| Type | Description |
|---|---|
| FilterExpression |
IncrementUsageCount
Gets or sets whether the usage count property of a translation unit should be modified upon use.
Declaration
public bool IncrementUsageCount { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
InvalidTranslationUnitsExportPath
If non-null, invalid translation units (or those which produce import errors) will be written to the specified output file.
Declaration
public string InvalidTranslationUnitsExportPath { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String |
IsDocumentImport
Gets or sets whether this is a document import. If yes, contextual information will be saved into the translation memory.
Declaration
public bool IsDocumentImport { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
NewFields
Gets or sets the value indicating the new fields behavior.
Declaration
public ImportSettings.NewFieldsOption NewFields { get; set; }
Property Value
| Type | Description |
|---|---|
| ImportSettings.NewFieldsOption |
OverrideTuUserIdWithCurrentContextUser
Gets or sets the value that indicate if the TM importer will override the user id received from client.
Declaration
public bool OverrideTuUserIdWithCurrentContextUser { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
OverwriteExistingTUs
Gets or sets a flag indicating whether existing TUs (those with the same source segment) should be deleted. Note that all such existing TUs will be deleted from the TM before the new TU is being added. This effectively removes all potential duplicates in the target TM.
Declaration
[Obsolete("OverwriteExistingTUS property is obsolete, please use ExistingTUsUpdateMode instead.")]
public bool OverwriteExistingTUs { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
PlainText
Gets or sets whether the input is plain text or it may contains tags.
Declaration
public bool PlainText { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
ProjectSettings
Gets or sets the project settings.
Declaration
public FieldValues ProjectSettings { get; set; }
Property Value
| Type | Description |
|---|---|
| FieldValues |
SegmentLengthLimit
Gets or sets the value that indicate if the TM importer will ignore TU with segments (Source or Target) with the length (number of characters) over specified limit.
Declaration
public int? SegmentLengthLimit { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Nullable<System.Int32> |
TagCountLimit
Gets or sets the limit for the number of tags any TU segment may contain in order to be imported. The default value is DefaultTagCountLimit. If the limit is exceeded, the TU will not be imported and an error will be generated.
If the value is 0, no limit will be applied.
Declaration
public int TagCountLimit { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Int32 |
TagNestingLimit
Gets or sets the limit for the number of nested tags any TU segment may contain in order to be imported. If the limit is exceeded, the TU will not be imported and an error will be generated.
If the value is null, no limit will be applied.
Declaration
public int? TagNestingLimit { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Nullable<System.Int32> |
TUProcessingMode
Gets or sets the TU Processing Mode to be applied to the import.
Declaration
public ImportSettings.ImportTUProcessingMode TUProcessingMode { get; set; }
Property Value
| Type | Description |
|---|---|
| ImportSettings.ImportTUProcessingMode |
UserName
Gets/Sets the user display name which is performing the operation
Declaration
public string UserName { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String |
UseTmUserIdFromBilingualFile
Gets or sets the value indicating the location that is used for user id when importing TUs.
Declaration
public bool UseTmUserIdFromBilingualFile { get; set; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |