Click or drag to resize
IMultiFileConverter Interface
Used for converting and processing content from one or more files as a single bilingual document.

Namespace: Sdl.FileTypeSupport.Framework.IntegrationApi
Assembly: Sdl.FileTypeSupport.Framework.Core (in Sdl.FileTypeSupport.Framework.Core.dll) Version: 1.0.0.0 (1.0.2343.0)
Syntax
public interface IMultiFileConverter : IBilingualProcessorContainer

The IMultiFileConverter type exposes the following members.

Methods
  NameDescription
Public methodAddBilingualProcessor
Appends a bilingual content processor to the container.
(Inherited from IBilingualProcessorContainer.)
Public methodAddExtractor
Adds another file converter to be used. The converter should be initialized properly.
Public methodApplyDocumentPropertiesToExtractors
Updates the file properties for each of the extractors to use the source and target languages specified in the document properties.
Public methodGetBilingualProcessors
The content processors, in the order in which they will be invoked
(Inherited from IBilingualProcessorContainer.)
Public methodInsertBilingualProcessor
Inserts a bilingual processor at a specified position in the container. Any item that is currently occupying that position will - after this operation - appear after the inserted processor.
(Inherited from IBilingualProcessorContainer.)
Public methodInsertExtractor
Inserts a file converter to be used at a specific index. The converter should be initialized properly.
Public methodParse
Initializes the file type components and repeatedly invokes the ParseNext method on the parser until all content has been processed. If there is a native parser, it will be used. Otherwise ,if there is a bilingual parser, that parser will be used. If no parser has been specified, an exception will be thrown.
Public methodParseNext
Invokes the ParseNext() method on the appropriate parser, causing a chunk of content to be processed. Ensures that the the parser components are initialized before parsing commences for the first time.
Public methodRemoveBilingualProcessor
(Inherited from IBilingualProcessorContainer.)
Public methodRemoveExtractor
Removes the specified converter.
Public methodSetDocumentInfo
Set document properties, optionally updating source and target languages for each of the extractors.
Public methodSynchronizeDocumentProperties
Properly synchronizes document properties between the converter and its extractors. If document properties are available from a bilingual parser, they will be used. Otherwise, the document properties will be deducted by querying existing extractors for languages.
Public methodUpdateDocumentPropertiesFromExtractors
Set source and target languages of the document properties from the properties detected by the file sniffers associated with the extractors. If different extractors have detected differing languages with certainty, this method does not change the document properties and returns false. If different languages are detected with a detection level less then certain, the language with the highest detection level will be used. If there is more than one language, the first one will take precedence.

If a target language has been set in the document properties, but no target language has been detected in the extractors, the target language of the document properties will be set to an uninitialized value.

Top
Properties
  NameDescription
Public propertyBilingualDocumentGenerator
The purpose of a bilingual generator is to serialize all bilingual content (potentially from different native files) into a single bilingual output (e.g. an XLIFF file) that will act as a persistent storage for the bilingual content, from which it can be fully de-serialized.
Public propertyBilingualDocumentOutputProperties
After saving a bilingual document, this property provides access to the output properties that were used. This can be used to find the file name of the created output file and to determine which dependency files are referenced (linked) to the file rather than embedded inside the file.
Public propertyBilingualDocumentOutputPropertiesProvider
When writing bilingual document files (e.g. SDL XLIFF), this property must be set. The delegate is called by the converter to determine the file name of the bilingual document to be created.
Public propertyBilingualVerifiersProvider
In order to add the file specific verifiers into the processing chain, we can specify a BilingualVerifiersProvider. A default implementation is provided by the FileTypeManager. If no bilingual verification is required, this property should be left null.
Public propertyDependencyFileLocator
When parsing intermediate bilingual documents this property may be set to provide assistance in locating missing linked dependency files. The provided delegate will be passed to any bilingual document parsers before they are used for processing.
Public propertyDetectedLanguagesCorrespondToDocumentProperties
True if the source and target languages in the DocumentInfo correspond to the languages detected by the file sniffers for each of the extractors. False if any of the extractors is certain that its file is using a different source or target language.
Public propertyDetectedSourceLanguage
The source language for all extractors, or null if conflicting source languages have been determined with certainty. The detection level that is returned is the highest detection level for the source language provided by the extractors.
Public propertyDetectedTargetLanguage
The target language for all extractors, or null if conflicting target languages have been determined with certainty. The detection level that is returned is the highest detection level for the target language provided by the extractors.
Public propertyDocumentInfo
Common properties communicated to all bilingual processing components
Public propertyExtractors
Read-only access to the file extractors used for reading files.
Public propertyFileRestriction
This delegate will be invoked for each file to be processed. If the delegate returns true, the file will be processed as normal, but if it returns false, the file will be skipped.
(Inherited from IBilingualProcessorContainer.)
Public propertyItemFactory
The bilingual content model item factory that will be used by the converters and bilingual file type components
Public propertyNativeGeneratorProvider
When converting to native format, this property represents the provider that will attempt to create IFileGenerator instances, and provide output settings when needed by the framework. This property should be null if not converting to native format.
Public propertyOutputPropertiesProvider
When converting to native format, this property must be set. This delegate is called by the converter to set the output filename, encoding, language, etc. for each native file produced.
Public propertyParagraphUnitRestriction
If set, this delegate will be invoked for each paragraph unit to be processed. If the delegate returns true, the paragraph unit will be processed as normal. If it returns false, the paragraph unit will be skipped.
(Inherited from IBilingualProcessorContainer.)
Public propertyPropertiesFactory
Convenience getter for the properties factory that will be used by the converters and file type components. The implementation should return the properties factory from the document item factory, or null if none.
Public propertySharedObjects
The shared objects that will be communicated across all components that are used in content processing. Components that implement ISharedObjectsAware will receive this interface via the SetSharedObjects(ISharedObjects) method before they are used for content processing.
Top
Events
  NameDescription
Public eventMessage
Raised when a message is reported from a file type component.
Public eventProgress
This event is fired when any of the the native or bilingual parser fires progress events.

The reported progress constitutes the computed total progress for all files being processed.

Top
See Also
Community
Edit
Be the first to Edit the community content of this topic.
Comments