Mapping the input of the activity

In this task, you map the XML variable containing the MIME header part of the mail header and the string variable containing the body of the message to the mimeheader and body input parameters of the Read MIME activity, respectively. Variables must be mapped to the mime header and body input parameters—both input parameters are required. The mime header input parameter is of type XML and the body input parameter is of type string.

About this task

The following table defines the elements in the mimeheader input parameter:
Table 1.
Element Name Default
mimeVersion Currently not used.
contentType/mainType Currently not used. The Read MIME activity determines if the message is multipart or not by parsing the message using the specified boundary delimiter
contentType/subType Currently not used.
contentType/charset Currently not used.
contentType/attribute/name – contentType/attribute/value The attribute element contains a set of attributes as name/value pairs. You can specify the boundary attribute that specifies the boundary delimiter between the multipart entities of the message. If you specify the boundary attribute, it overrides the default boundary set in the message itself. If no boundary attribute is specified in the message itself or using the attribute element, an exception is thrown during run time.
contentTransferEncoding Currently not used.
otherMimeHeaders Currently not used.
The message body can contain one or more MIME parts separated by the boundary value specified in the contentType/attribute element of the mimeheader input parameter. Each part contains a MIME header that describes various attributes of the associated part body. How the individual part is parsed depends on the values assigned to the following parameters in the entityMimeHeader of the entity body:
  • Content-Type header
  • Charset attribute within the Content-Type header
  • Content-Transfer-Encoding

How the part body is parsed depends on the settings of Content-Transfer-Encoding and Content-Type:

Content-Type is equal to “text:”
  • If the Content-Type is “text” and the Content-Transfer-Encoding is “7-bit”/”8-bit” or “binary,” the part body is converted to an UTF8 encoded string and copied into the entityBody element of the parts output parameter.
  • If the Content-Type is “text” and the Content-Transfer-Encoding is “quoted-printable,”the part body is quoted-printable decoded, converted to an UTF8 encoded string based on the charset attribute and copied into the entityBody element of the parts output parameter.
  • If the Content-Type is “text” and the Content-Transfer-Encoding is “base64,” the part body is base64 decoded, converted to an UTF8 encoded string based on the charset attribute and copied into the entityBody element of the parts output parameter.

If not explicitly specified in the part MIME header, charset defaults to UTF8. The only exception to this default behavior is when the Content-Disposition is equal to “attachment” and the Content-Type is equal to “text." In this case, the part is not be treated as text since the charset of the data cannot be known. In addition, the Content-Transfer-Encoding is set to "binary."

Content-Type is not equal to “text:”
  • If the Content-Type is not equal to “text” and the Content-Transfer-Encoding is “7bit”/”8bit” or “binary,” the part body is converted to an UTF8 encoded string and copied into the entityBody element of the parts output parameter.
  • If the Content-Type is not equal to “text” and the Content-Transfer-Encoding is “quoted-printable,” the part body is quoted-printable decoded, base64 encoded, and copied into the entityBody element of the parts output parameter.
  • If the Content-Type is not equal to “text” and the Content-Transfer-Encoding is “base64,” the part body is copied as is (base64 data) into the entityBody element of the parts output parameter.



Feedback | Notices


Timestamp icon Last updated: Tuesday, 27 September 2016


http://pic.dhe.ibm.com/infocenter/wci/v7r0m0/topic/com.ibm.wci.doc/Map_Activity_Input_Read_MIME.html