Configuring the Behavior of the Send Dependent Items Check Box in the Configuration File

The Send Dependent Items check box is displayed in:

  • the Choose Items page of the Bulk Translation wizard
  • the Automatic Item Export for Translation dialog box

By default, if the Send Dependent Items check box is selected, the Connector sends out data source items from the layout and final layout of the item itself. For a detailed illustration and scenarios of the default behavior of the Send Dependent Items check box, see Understanding the Send Dependent Items Check Box.

Alternatively, you can develop your own pipeline to determine which dependent items the Connector sends for translation when this check box is selected. You configure this pipeline in the <pipelines> section of the Website_root/Website/App_Config/Include/CT3Translation.config configuration file. If the Send Dependent Items check box is selected and the pipeline is defined, then when you run the Bulk Translation wizard:

  1. The Connector calls the pipeline for each selected item.

  2. On its own, the pipeline finds dependent items recursively.

Important: The pipeline overrides the default Connector behavior of sending out only data source items of the item itself. The Connector does not call the pipeline again using a dependent item as a source for recursively searching for additional dependent items.

  1. The Connector adds the results to the list of items to send out for translation.
To develop a pipeline:
  1. Insert the logic to recursively determine all dependent items of an item to send out for translation, similar to the following example:

<CustomRecursiveDependentItemsPipeline>

<!-- Insert the logic to recursively determine all dependent items of an item to send out for translation.

–>

<processor type=“Your.Class, Your.Assembly” method=“getDependentItems”/>

</CustomRecursiveDependentItemsPipeline>

  1. Ensure that the processor method has the following signature:

public void getDependentItems(ClayTablet.SC.Pipelines.DependentItemsPipelineArgs args);

  1. Use the args parameter to retrieve information about a source item. You will search for dependent items of this source:

public class DependentItemsPipelineArgs {

String ItemDatabase { get; }

String ItemId { get; }

String SourceLanguage { get; }

String SourceVersion { get; }

String[] TargetLanguages { get; }

List<String> DependentItems { get; }

}

  1. Insert the item IDs of all dependent items of the source item into the DependentItems that the pipeline returns.