org.openeai.transport
Interface SyncService

All Known Implementing Classes:
PubSubProducer

public interface SyncService


Method Summary
 void createSync(ActionableEnterpriseObject theObject)
          Create Sync message production.
 void deleteSync(java.lang.String deleteAction, ActionableEnterpriseObject theObject)
          Delete Sync message production.
 ProducerId getProducerId(java.lang.String dummyParm)
           
 int incrementMessageSequence()
           
 boolean publishMessage(ActionableEnterpriseObject theObject, org.jdom.Document doc)
           
 void setProducerId(ProducerId producerId)
           
 void updateSync(ActionableEnterpriseObject theObject)
          Update Sync message production.
 

Method Detail

createSync

void createSync(ActionableEnterpriseObject theObject)
                throws TransportException
Create Sync message production. Builds an XML document (using the primed create sync document as a baseline) out of the current contents of the object. While building the XML Create Sync document, it will validate contents of the object checking for any malformed, missing or invalid fields. Field data values are also checked for validitity against the EnterpriseObjects document. Publishes the XML document in a JMS message to the topic connected to by producer.

Parameters:
producer - org.openeai.jms.producer.PubSubProducer to use to publish the message.
Throws:
EnterpriseObjectSyncException - if any errors occur when validating the contents of the object. Or, if any errors occur while publishing the message.
TransportException

deleteSync

void deleteSync(java.lang.String deleteAction,
                ActionableEnterpriseObject theObject)
                throws TransportException
Delete Sync message production. Builds an XML document (using the primed delete sync document as a baseline) out of the current contents of the object. While building the XML Delete Sync document, it will validate contents of the object checking for any malformed, missing or invalid fields. Field data values are also checked for validitity against the EnterpriseObjects document. Publishes the XML document in a JMS message to the topic connected to by producer.

Parameters:
deleteAction - String delete action ('purge' or 'delete')

producer - PubSubProducer a pre-configured and started PubSubProducer which will be used to send the delete-sync message to the appropriate destination (via the PubSubProducer.publishMessage method).

Throws:
EnterpriseObjectSyncException - if any errors occur when validating the contents of the object. Or, if any errors occur while publishing the message.
TransportException

updateSync

void updateSync(ActionableEnterpriseObject theObject)
                throws TransportException
Update Sync message production. Builds an XML document (using the primed update sync document as a "template") out of the current contents of the object. It will use the current contents of the object as the NewData portion of the message and it will use the m_baseline object as the Baseline portion of the message. The m_baseline object is set when this object was "queried" for previously. While building the XML Update Sync document, it will validate contents of the object checking for any malformed, missing or invalid fields. Field data values are also checked for validitity against the EnterpriseObjects document. Publishes the XML document in a JMS message to the topic connected to by producer.

Parameters:
producer - PubSubProducer a pre-configured and started PubSubProducer which will be used to send the delete-sync message to the appropriate destination (via the PubSubProducer.publishMessage method).

Throws:
EnterpriseObjectSyncException - if any errors occur when validating the contents of the object. Or, if any errors occur while publishing the message.
TransportException

publishMessage

boolean publishMessage(ActionableEnterpriseObject theObject,
                       org.jdom.Document doc)
                       throws TransportException
Throws:
TransportException

getProducerId

ProducerId getProducerId(java.lang.String dummyParm)

setProducerId

void setProducerId(ProducerId producerId)

incrementMessageSequence

int incrementMessageSequence()


Copyright © 2002,2003 OpenEAI Software Foundation