Designing processes - EMC Community Network

Designing processes - EMC Community Network Designing processes - EMC Community Network

community.emc.com
from community.emc.com More from this publisher
30.01.2015 Views

Designing the Process To copy all values of a multi-valued attribute to a specific index of multi-valued indexes: 1. In the target tree, create a node representing the specific index of the multi-valued attribute. 2. Select the node representing all values (the index value for this node is ALL) in the source tree. 3. Select the node representing the single-attribute node in the source tree. 4. Launch the function dialog box by double-clicking on the function. 5. In the function dialog box, select FOR-EACH as the value for Input Context, and select Over-Write, Insert Before, or Insert After as the value of Output Context. When using the Insert After or Insert Before options, the values are inserted after or before the index. When using the Overwrite option, the existing values are overwritten. XML and other data formats Since Extensible Markup language (XML) is the standard used to exchange structured data between applications, the activity templates shipped with Process Builder support XML natively. Process designers can associate an XML schema with a service-specific message and use the data mapper to create an XML payload that can be sent to other applications. However, if the target application uses another data format (like Comma Separated Value (CSV)), then associate a translator with the message. At runtime, the Process Integrator uses a translator, if specified in data mapper, to convert the XML document into the desired format. A translator is a custom Business Object Framework (BOF) module that you write, for example, to convert a Comma Separated Variable (CSV) file to an XML document. This is a standard feature of the data mapper. Setting custom object types for attachments In some applications, executing processes must receive email with attachments. The default object type for an attachment is dm_document. However, you can also treat it as a custom object type by using the data mapper for the Email Inbound activity template. In the data mapper, set the ObjectType attribute in the Attachments node of the process data to any type that is valid for your repository. Looping Many applications must perform a series of activities several times in succession. Process Builder enables you to define loops by using a counter mechanism. The following process shows how to set up looping within a process. In the first activity, a human performer specifies a set of departments. Then, an automated loop cycles through each department, invoking a process for each department. 42 EMC Documentum xCelerated Composition Platform Version 1.6 Best Practices Guide

Designing the Process To create a simple loop: 1. Create a manual activity called Define Departments in which the user defines the departments for which a new process is started. 2. Create a Process Data Mapping activity called Setup Loop. This activity gets the number of departments defined in the manual activity and assigns that number to a counter. 3. Use another data mapping activity to decrement the CurrentCount by 1. Use a Subtract function to subtract 1 from CurrentCount and map it back to the same variable. It is valid to map the variable back to itself to get: CurrentCount = CurrentCount -1. This is necessary EMC Documentum xCelerated Composition Platform Version 1.6 Best Practices Guide 43

<strong>Designing</strong> the Process<br />

To copy all values of a multi-valued attribute to a specific index of multi-valued indexes:<br />

1. In the target tree, create a node representing the specific index of the multi-valued attribute.<br />

2. Select the node representing all values (the index value for this node is ALL) in the source tree.<br />

3. Select the node representing the single-attribute node in the source tree.<br />

4. Launch the function dialog box by double-clicking on the function.<br />

5. In the function dialog box, select FOR-EACH as the value for Input Context, and select<br />

Over-Write, Insert Before, or Insert After as the value of Output Context.<br />

When using the Insert After or Insert Before options, the values are inserted after or before the<br />

index. When using the Overwrite option, the existing values are overwritten.<br />

XML and other data formats<br />

Since Extensible Markup language (XML) is the standard used to exchange structured data between<br />

applications, the activity templates shipped with Process Builder support XML natively. Process<br />

designers can associate an XML schema with a service-specific message and use the data mapper to<br />

create an XML payload that can be sent to other applications. However, if the target application<br />

uses another data format (like Comma Separated Value (CSV)), then associate a translator with the<br />

message. At runtime, the Process Integrator uses a translator, if specified in data mapper, to convert the<br />

XML document into the desired format. A translator is a custom Business Object Framework (BOF)<br />

module that you write, for example, to convert a Comma Separated Variable (CSV) file to an XML<br />

document. This is a standard feature of the data mapper.<br />

Setting custom object types for attachments<br />

In some applications, executing <strong>processes</strong> must receive email with attachments. The default object<br />

type for an attachment is dm_document. However, you can also treat it as a custom object type by<br />

using the data mapper for the Email Inbound activity template. In the data mapper, set the ObjectType<br />

attribute in the Attachments node of the process data to any type that is valid for your repository.<br />

Looping<br />

Many applications must perform a series of activities several times in succession. Process Builder<br />

enables you to define loops by using a counter mechanism. The following process shows how to set up<br />

looping within a process. In the first activity, a human performer specifies a set of departments. Then,<br />

an automated loop cycles through each department, invoking a process for each department.<br />

42 <strong>EMC</strong> Documentum xCelerated Composition Platform Version 1.6 Best Practices Guide

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!