Business object structure

The TPI connector has two requirements for the business objects it processes:

Child meta-object attributes

Each business object sent from a business process to the connector must contain a single-cardinality meta-object as a cardinality 1 child. The meta-object contains the dynamic meta-data required by the connector to call the appropriate data handler for converting the object, and to call the sendDocument() method in the TPI Server API. Table 12 lists the attributes of the meta-object. All of the listed attributes must be defined in the business object definition.

Table 12. Meta-object attributes for TPI connector

Attribute name Description Default value
DocumentExt Specifies the document's file extension; used during request processing.
DocumentType Specifies the format of the document--XML, EDI, or binary. binary
BOPrefix Used with the MIME type to create an instance of the XML data handler.
SenderID Specifies the unique TPI ID for the trading partner that is sending the document. Default value must be set by user.
ReceiverID Specifies the unique TPI ID for the trading partner that is receiving the document. Default value must be set by user.
UniqueID Specifies the unique identifier assigned to each document by the TPI Server. This attribute is optional, but may used for processing business object requests.
OriginalName Specifies the prefix used to name the document object file that is written to the document out directory. Must be set by user.
WaitForMDN Determines whether the connector waits for an MDN from the TPI Server after sending the document. true
BackupRequired Determines whether the TPI Server creates a backup copy of the document after sending it to the trading partner. true

DocumentExt

The DocumentExt attribute enables you to specify file extensions (for example, .xml or .edi) during request processing. It is an optional attribute, and has no default value.

DocumentType

The DocumentType attribute is used with the ReceiverID attribute to get the document MIME type from the trading partner configuration file. The connector uses the MIME type to invoke the appropriate data handler. The default value is binary.

The DocumentType attribute can also accept the special value CW_RNIF. In this situation, you do not need to specify a value for the ReceiverID attribute; it is not used by the connector.

BOPrefix

The BOPrefix is used with the MIME type by the connector to invoke the appropriate data handler instance. If the data handler implementation handles only one MIME type, the BOPrefix attribute in a child meta-object is optional.

SenderID

The SenderID is the unique partner ID of the document sender. This value is used by the connector to build the DefaultDocument object, which is passed in the sendDocument() call.

ReceiverID

The ReceiverID is the unique ID of the trading partner to whom the document is being sent. This value is used with the DocumentType attribute to get the document MIME type from the trading partner configuration file. It is also used to build the DefaultDocument object, which is passed in the sendDocument() call. This attribute is optional, but may used for business object processing.

UniqueID

The unique identifier assigned to each document by the TPI Server.

Original Name

The prefix used to name the output file that the connector writes to the DocumentOutDir directory for retrieval by the TPI Server. The ObjectEventId is appended to this name to guarantee uniqueness.

WaitForMDN

This attribute determines whether the connector waits for notification from TPI that the MDN was received for the document. This attribute is optional. If this attribute is populated in the meta-object, it overrides the connector's WaitForMDN property. The default value is true.

BackupRequired

This attribute sets a flag to have the TPI Server back up the document after sending it. This attribute is optional. If this attribute is populated, it overrides the BackupRequired connector property. This value is passed as a parameter in the sendDocument() call. The default value is true.

Data handler requirements for business object structure

Each data handler used by the TPI connector has its own requirements for business object structure. Business objects must conform to the specifications of the data handler called to convert the them. These requirements are documented in the Data Handler Guide.

Sample business object with child meta-object

The following is an example of a TPI connector business object definition with the meta-object as a cardinality 1 child. This business object definition was developed for the delimited data handler.

[BusinessObjectDefinition]
Name = TPICustBO
Version = 1.0.0.
AppSpecificInfo = cw_mo_cfg=CustBORouteInfo;
 
[Attribute]
Name = FirstName
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
[end]
 
[Attribute]
Name = LastName
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
[end]
 
[Attribute]
Name = Company
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
[end]
 
[Attribute]
Name = City
Type = String
IsKey = false
IsRequired = false
AppSpecificInfo =
[end]
 
[Attribute]
Name = CustBORouteInfo
Type = TPIRouteInfo
ContainedObjectVersion = 1.0.0.
Relationship = Containment
Cardinality = 1
MaxLength = 0
IsKey = false
IsForeignKey = false
IsRequired = false
DefaultValue = 
AppSpecificInfo = type=cw_mo_cfg
[end]
 
[Attribute]
Name = ObjectEventId
Type = String
MaxLength = 255
IsKey = false
IsForeignKey = false
IsRequired = false
[End]
 
[Verb]
Name = Create
[End]
 
[Verb]
Name = Retrieve
[End]
 
[End]
 
[BusinessObjectDefinition]
Name = TPIRouteInfo
Version = 1.0.0.
 
[Attribute]
Name = SenderId
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
[end]
 
[Attribute]
Name = ReceiverId
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
[end]
 
[Attribute]
Name = DocumentType
Type = String
IsKey = true
IsRequired = true
AppSpecificInfo =
 
[end]
 
[Attribute]
Name = BOPrefix
Type = String
IsKey = false
IsRequired = false
AppSpecificInfo =
[end]
 
[Attribute]
Name = WaitForMDN
Type = String
IsKey = false
IsRequired = false
AppSpecificInfo =
[end]
 
[Attribute]
Name = BackupRequired
Type = String
IsKey = false
IsRequired = false
AppSpecificInfo =
[end]
 
[Attribute]
Name = OriginalName
Type = String
IsKey = false
IsForeignKey = false
IsRequired = false
DefaultValue = TPICustomer
[End]
 
[Attribute]
Name = UniqueId
Type = String
IsKey = false
IsForeignKey = false
IsRequired = false
[end]
 
[Attribute]
Name = ObjectEventId
Type = String
MaxLength = 255
IsKey = false
IsForeignKey = false
IsRequired = false
[End]
 
[Attribute]
Name = OriginalName
Type = String
IsKey = false
IsForeignKey = false
IsRequired = false
DefaultValue = TPICustomer
[End]
 
[Attribute]
Name = UniqueId
Type = String
IsKey = false
IsForeignKey = false
IsRequired = false
[end]
 
[Verb]
Name = Create
[End]
 
[Verb]
Name = Retrieve
[End]
 
[End]

Copyright IBM Corp. 1997, 2003