To convert a business object to a string, the Delimited data handler loops
through the attributes of a business object in sequential order. It
generates Delimited formatting recursively in the order in which attributes
appear in the business object and its children. The name of the
business object is passed as an argument to the conversion method.
The Delimited data handler processes business objects into delimited data
as follows:
- The data handler creates a string to contain the data in the business
object.
- The data handler adds the business object name as the first token in the
string and adds the verb as the second a token in the string.
- The data handler examines the application-specific information in the
business object definition to determine if there are any child meta-objects
(those whose names are listed in the cw_mo_ tag of the business
object application-specific information). The data handler does
not include these attributes in the delimited data.
- The data handler looks for the meta-object attribute named
OmitObjectEventId. If this is set to true, the
data handler does not include ObjectEventId data of the business
object in the delimited data.
- The data handler loops through the remaining business object attributes in
order, adding values for each simple attribute to the string and adding the
configured delimiter after each attribute. For container attributes,
the data handler does the following:
- If the attribute is a cardinality 1 container, the data handler adds the
attribute count to the string, and then recursively processes the child
business object to add values for each attribute.
- If the attribute is a cardinality n container, the data handler adds the
count of the child objects in the container to the string, and then
recursively processes each child business object, adding values for each
attribute to the string.
- When the data handler completes the conversion, it returns the serialized
data to the caller. The data handler returns the data in the form
(String or InputStream) requested by the caller.
The format that the data handler generates conforms to the following
pattern:
Bus_Obj_Name<delimiter>Verb<delimiter>Attr1<delimiter>Attr2<delimiter>
Number_of_child_object_instances<delimiter>Child_Object_Name<delimiter>Verb
<delimiter>Attr1<delimiter>Attr2<EndBO:Bus_Obj_Name>
An escape string is appended in front of any delimiter-like string in an
attribute value. The escape string is configured using the
Escape attribute of the child meta-object.
