To use the Request-Response data handler, you must create or modify business object definitions so that they provide the structure that the data handler requires. However, unlike other data handlers, you do not need to modify business object definitions so that they contain meta-data. This section provides the information you need to create business object definitions to work with the Request-Response data handler. In particular, it provides the following information:
The Request-Response data handler uses business object definitions when it receives business object from or sends business objects to its request or response data handler. The Request-Response data handler places specific requirements on the structure of business objects it can process. Business objects passed to the data handler must contain one request child object and one or more response child objects. These child objects must conform to the requirements of the data handler that will process them.
Figure 33 shows the structure of the business objects that represent a Request-Response business object.
Figure 33. Business object structure for a request-response business object
To ensure that business object definitions conform to the requirements of the Request-Response data handler, use the guidelines provided for each of the following business objects:
The Request-Response data handler expects a top-level business object to
hold the information it receives from or sends to its calling context. Table 48 describes how the Request-Response data handler interprets
the properties of a business object and describes how to set the properties
when modifying a business object for use with the Request-Response data
handler.
Table 48. Properties for the top-level business object definition
This top-level business object must contain the following attributes:
This request business object must conform to any business-object requirements that the request data handler requires.
The response business object must conform to any business-object requirements that the response data handler requires.
Notes:
For example, if the target application could return either a Customer XML document or an OrderUpdate XML document, the top-level business object definition must include two attributes, one to hold the business object definition that represents the Customer XML document, and the second to hold the businesss object definition that holds the OrderUpdate XML document. When it received the response business object, the data handler would populate the appropriate attribute.
To hold the request information for the request data handler, the
Request-Response data handler expects a request business object as the first
attribute of the top-level business object. This attribute should be of
single cardinality. Table 49 describes how the Request-Response data handler interprets
the properties of this business object definition and describes how to set
these properties when modifying the business object for use with the
Request-Response data handler.
Table 49. Properties for the request business object definition
For example, if you specified RequestDataHandlerMimeType as text/xml, the child object you define as your request business object must be compatible with the XML data handler.
To hold the response information for the response data handler, the
Request-Response data handler expects a response business object in the
attributes starting with the second attribute of the top-level business
object. This attribute should be of single cardinality. If the
response data handler might return more than one type of business object, the
top-level business object has an attribute for each possible type. Table 50 describes how the Request-Response data handler interprets
the properties of this business object definition and describes how to set
these properties when modifying the business object for use with the
Request-Response data handler.
Table 50. Properties for the response business object definition
For example, if you specified ResponseDataHandlerMimeType as text/abc, the child object you define as your request business object must be compatible with a custom data handler that can handle the abc MIME type.
This section describes how to create business object definitions to represent the structure that the Request-Response data handler expects. Use Business Object Designer to add or delete attributes from the business object definition as well as edit attribute properties, as needed.
As described in Understanding Request-Response business object structure, the Request-Response data handler requires that you create the following business object definitions:
To create the top-level business object definition for the Request-Response data handler, you must manually create a business object definition using Business Object Designer:
For information on the structure of this top-level business object, see Top-level business object.
Table 51. Business objects for the Request-Response data handler
Attribute | Notes | Business object |
---|---|---|
Request business object | Contains the information about the request. | Request business object |
Response business object | Contains the information about the request's response | Response business object |
To create the request and response business object definitions, you can use either of the following ways:
For information on the XML ODA, see Appendix A, Using the XML ODA. For information on other ODAs, refer to the corresponding adapter guide.
For more information, see Creating the top-level business object definition