Home > Articles > Web Development

  • Print
  • + Share This
This chapter is from the book

The Business Object Framework

The computer software industry has developed several programming models and frameworks that enable developers to encapsulate business object information. In general, a BO framework should provide database independence, transparently map custom business objects to database tables, and bind business objects to user interfaces. Of late, XML schemas are perhaps the most popular and accepted way to represent the structure of a business object.

From a tooling perspective, WebSphere Integration Developer (WID) provides developers with a common BO model for representing different kinds of entities from different domains. At development time, WID represents business objects as XML schemas. At runtime, however, those same business objects are represented in memory by a Java instance of an SDO. SDO is a standard specification that IBM and BEA Systems have jointly developed and agreed on. IBM has extended the SDO specification by including some additional services that facilitate the manipulation of data within the business objects. We'll discuss some of these later in this chapter.

Before we get into the BO framework, let's look at the basic types of data that get manipulated:

  • Instance data is the actual data and data structures, from simple, basic objects with scalar properties to large, complex hierarchies of objects. This also includes data definitions such as a description of the basic attribute types, complex type information, cardinality, and default values.
  • Instance metadata is instance-specific data. Incremental information is added to the base data, such as change tracking (also known as change summary), context information associated with how the object or data was created, and message headers and footers.
  • Type metadata is usually application-specific information, such as attribute-level mappings to destination enterprise information system (EIS) data columns (for example, mapping a BO field name to a SAP table column name).
  • Services are basically helper services that get data, set data, change summary, or provide data definition type access.

Table 2.1 shows how the basic types of data are implemented in the WebSphere platform.

Table 2.1. Data Abstractions and the Corresponding Implementations

Data Abstraction

Implementation

Instance data

Business object (SDO)

Instance metadata

Business graph

Type metadata

Enterprise metadata

 

Business object type metadata

Services

Business object services

Working with the IBM Business Object Framework

As we mentioned, the WPS BO framework is an extension of the SDO standard. Therefore, business objects exchanged between WPS components are instances of the commonj.sdo.DataObject class. However, the WPS BO framework adds several services and functions that simplify and enrich the basic DataObject functionality.

To facilitate the creation and manipulation of business objects, the WebSphere BO framework extends SDO specifications by providing a set of Java services. These services are part of the package named com.ibm.websphere.bo:

  • BOFactory: The key service that provides various ways to create instances of business objects.
  • BOXMLSerializer: Provides ways to "inflate" a business object from a stream or to write the content of a business object, in XML format, to a stream.
  • BOCopy: Provides methods that make copies of business objects ("deep" and "shallow" semantics).
  • BODataObject: Gives you access to the data object aspects of a business object, such as the change summary, the business graph, and the event summary.
  • BOXMLDocument: The front end to the service that lets you manipulate the business object as an XML document.
  • BOChangeSummary and BOEventSummary: Simplifies access to and manipulation of the change summary and event summary portion of a business object.
  • BOEquality: A service that enables you to determine whether two business objects contain the same information. It supports both deep and shallow equality.
  • BOType and BOTypeMetaData: These services materialize instances of commonj.sdo.Type and let you manipulate the associated metadata. Instances of Type can then be used to create business objects "by type."

Chapter 4, "WebSphere Integration Developer," introduces the facilities that WID provides to enable you to quickly formulate your object definitions.

  • + Share This
  • 🔖 Save To Your Account

Related Resources

There are currently no related titles. Please check back later.