70 WebSphere Business Integration Adapters
Outcome status for Delete verb processing
The Delete operation should return one of the outcome status values as shown
in Table 6-7.
Table 6-7 Possible outcome status for Delete verb processing
6.7 Business object processing and cardinality
A business object handler’s role is to deconstruct a request business object,
process the request, and perform the requested operation in the application. To
do this, a business object handler extracts verb and attribute information from the
request business object and generates an API call, SQL statement, or other type
of application interaction to perform the operation.
Basic business object processing involves extracting metadata from the
business object’s application-specific information (if it exists) and accessing the
attribute values. The actions to take on the attribute value depend on whether the
business object is
flat or hierarchical. This section provides an overview of how
a business object handler can process these types of business objects.
6.7.1 Processing flat business objects
If a business object does not contain any other business objects (called child
business objects), it is called a
flat business object. All the attributes in a flat
business object are simple attributes (that is, each attribute contains an actual
value, not a reference to another business object).
After the verb operation has accessed the information that it needs within the
business object definition, it often needs to access information about attributes.
Attribute properties include the cardinality, key or foreign key designation, and
maximum length. For example, the Create method might need to obtain the
attribute’s application-specific information. A connector business object handler
Delete condition Outcome status
InterChange Server only: In most cases, the
connector returns a “Value Changed” outcome status
to enable the system to clean up the relationship
tables after a delete operation.
All integration brokers: If the Delete operation is
unsuccessful, it:
Fills a return-status descriptor with additional
information about the cause of the delete error.
Returns a “Fail” outcome status.
Chapter 6. Business object handlers 71
typically uses the attribute properties to decide how to process the attribute
For a
database-oriented application, the business object handler that handles a
flat business object, deconstructing a business object includes the following
1. Extracts the table and column names from the application-specific information
in the business object definition.
2. Extracts the values of the attributes from the business object instance.
As Figure 6-4 shows, the Customer business object definition is designed for a
metadata-driven connector. Its business object definition includes
application-specific information that the verb operation uses to locate the
application entity upon which operates.
Figure 6-4 Business object definition and business object instance
Important: Application-specific information is also used to store information
about foreign keys and other types of relationships between entities in the
application database. A metadata-driven connector can use this information to
build an SQL statement or an API call.
Business Object Definition
Business Object Instance
IsKey = True
Type = Integer
AppSpecificInfo = cust_key
Type = String
AppSpecificInfo = cust_name
Type = String
AppSpecificInfo = cust_status
Type = String
AppSpecificInfo = cust_region
Verb = Create
CustomerId = 1150
CustomerName = Jones
CustomerStatus = Active
CustomerRegion = North
72 WebSphere Business Integration Adapters
6.7.2 Processing hierarchical business objects
Business objects are hierarchical when parent business objects can contain child
business objects, which can, in turn, contain child business objects, and so on. A
hierarchical business object is composed of a
top-level business object, which is
the business object at the very top of the hierarchy, and
child business objects,
which are all business objects under the top-level business object. A child
business object is contained in a parent object as an attribute.
There are two types of containment relationships between parent and child
business objects:
Cardinality 1 containment: The attribute contains a single child business
Cardinality n containment: The attribute contains several child business
objects in a structure called a business object array.
Figure 6-5 shows a typical hierarchical business object. The top-level business
object has both cardinality 1 and cardinality n relationships with child business
Figure 6-5 Hierarchical business object
Cardinality 1
Cardinality n

Get WebSphere Business Integration Adapters: An Adapter Development and WebSphere Business Integration Solution now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.