Sun Java System Mobile Enterprise Platform 1.0 Developer's Guide for Enterprise Connectors

About the Enterprise Connector Business Object (ECBO) API

The Enterprise Connector Business Object (ECBO) API provides classes and methods that allow you to create an Enterprise Connector, which is a Java artifact that consists of extensions of five classes compiled and packaged into a JAR file along with a resource file.

The methods you implement in your connector are called by the MEP libraries deployed on the Gateway Engine. In this respect, the ECBO API is more like a Service Provider Interface (SPI) than an Application Programmer Interface (API).

Each connector defines a particular business object whose data is to be synchronized. It also defines commands and operations that allow the connector to perform Create, Retrieve, Update, and Delete (CRUD) operations on the business objects.

The five classes you must implement are called BusinessObject, BusinessObjectProvider, InsertCommand, UpdateCommand, and DeleteCommand. The BusinessObjectProvider class provides a method to perform the retrieve operation. Chapter 2, Creating an Enterprise Connector, describes in detail how to implement these classes.

The resource file is an XML file that is used by the underlying JCR implementation. It defines a repository name, a workspace name, and a few node types. All Enterprise Connectors use the same set of node types.

The data to be synchronized takes the form of arbitrary Java objects. The way in which these Java objects are serialized is open-ended and is part of the contract between an Enterprise Connector and its corresponding Java ME client. It is recommended that you use a format that supports data versioning.