Main Page | Packages | Class Hierarchy | Class List | Directories | File List | Class Members | Related Pages

org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener Interface Reference

Inheritance diagram for org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener:

org.openmobileis.modules.common.log.client.LogsSynchroListener org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener org.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener org.openmobileis.synchro.openmsp.protocol.test.TestOpenMSSyncListener org.openmobileis.database.fastobjectdb.synchro.client.OpenMSPFODBSyncListener List of all members.

Detailed Description

Title: OpenMobileIS project source
Description: Base classe that all processus involved in the synchronisation must implement.

Synchro listener are managed by the SynchroManager. The sendData method is call for sending synchronisation data and receiveData is call if there is an answer to send data. Synchronisation end when no data is added to the send data container For each listener, the synchronisation protocol manage an unique id that identity the synchronisation session; see OpenMobile Synchronisation Protocol.

Author:
Philippe Delrieu
Since:
JDK 1.1
Version:
1.0.

Definition at line 46 of file OpenMSPSyncListener.java.

Public Member Functions

void sendData (Message message) throws OpenMSPException
 Event sent when the sync manager sends a openML message to the server The specified message is the message use to construct the synchro message This method fill the message with listener commande container.
String getSyncName ()
 Return the name used to identiy the of the listener in the synchro processus.
void notifySynchroFailure ()
 The listener is called if the syncML command processing failed.
int getSynchroStatus ()
 Return the synchro status of the listener.
boolean isSyncOK ()
 return true if the synchronisation is OK for the listener.
void startSync (Credential cred, SynchroDescriptor synchrodescriptor) throws OpenMSPException
 Fire this event once a synchro is starting.
void endSync () throws OpenMSPException
 Fire this event once the current synchro is ended.
void receiveSyncCommand (ContainerMessage syncContainer, long newSyncNumber) throws OpenMSPException
 Event sent when the sync manager receives Sync command openML messages from the server.
void receiveMapCommand (ContainerMessage mapContainer) throws OpenMSPException
 Event sent when the sync manager receives MAP command openML messages from the server.
void receiveResultCommand (ContainerMessage resultContainer, ContainerMessage initialCommand) throws OpenMSPException
 Event sent when the sync manager receives RESULT openML messages from the server.
void receiveStatusCommand (Status statusCommande, ContainerMessage initialCommand) throws OpenMSPException
 Event sent when the sync manager receives STATUS openML messages from the server.

Static Public Attributes

static final int SYNCHRO_OK = Status.STATUS_OK
static final int SYNCHRO_FAILLED = Status.STATUS_FAILED


Member Function Documentation

int org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.getSynchroStatus  ) 
 

Return the synchro status of the listener.

The return value is defined by the OpenMSP Status class.

See also:
org.openmobileis.synchro.openmsp.protocol.Status

Implemented in org.openmobileis.modules.common.log.client.LogsSynchroListener, and org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.

String org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.getSyncName  ) 
 

Return the name used to identiy the of the listener in the synchro processus.

This name correspond to the source in the OpenMS protocol.

Implemented in org.openmobileis.database.fastobjectdb.synchro.client.OpenMSPFODBSyncListener, org.openmobileis.modules.common.log.client.LogsSynchroListener, org.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener, and org.openmobileis.synchro.openmsp.protocol.test.TestOpenMSSyncListener.

Referenced by org.openmobileis.synchro.openmsp.client.core.ListenerOrdonancer.addListener(), org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.DefaultOpenMSPSyncListener(), org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.endSync(), org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.equals(), org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener.getSyncDataForAtomicObjectUID(), org.openmobileis.synchro.openmsp.client.core.test.TestListenerOrdonancer.main(), org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener.manageReturnStatusLog(), org.openmobileis.synchro.openmsp.client.OpenMSPSynchroManager.notifyFailure(), org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.notifySynchroFailure(), org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener.receiveResultCommand(), org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener.receiveStatusCommand(), org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener.sendData(), org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.setSynchroStatus(), and org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.startSync().

void org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.receiveMapCommand ContainerMessage  mapContainer  )  throws OpenMSPException
 

Event sent when the sync manager receives MAP command openML messages from the server.

Parameters:
ContainerMessage container : container containing the message
long newSessionID : the session id use for this synchro for this listener message.

Implemented in org.openmobileis.modules.common.log.client.LogsSynchroListener, org.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener, org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener, and org.openmobileis.synchro.openmsp.protocol.test.TestOpenMSSyncListener.

Referenced by org.openmobileis.synchro.openmsp.client.core.OpenMSPSyncMessageFactory.receiveOpenMSPMessage().

void org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.receiveResultCommand ContainerMessage  resultContainer,
ContainerMessage  initialCommand
throws OpenMSPException
 

Event sent when the sync manager receives RESULT openML messages from the server.

Parameters:
Result resultCommande : resultCommande containing the result of a command
long newSessionID : the session id use for this synchro for this listener message.
ContainerMessage : command sent that generate the status.

Implemented in org.openmobileis.modules.common.log.client.LogsSynchroListener, org.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener, org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener, and org.openmobileis.synchro.openmsp.protocol.test.TestOpenMSSyncListener.

Referenced by org.openmobileis.synchro.openmsp.client.core.OpenMSPSyncMessageFactory.receiveOpenMSPMessage().

void org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.receiveStatusCommand Status  statusCommande,
ContainerMessage  initialCommand
throws OpenMSPException
 

Event sent when the sync manager receives STATUS openML messages from the server.

Parameters:
Status statusCommande : resultCommande containing the Status of a command
long newSessionID : the session id use for this synchro for this listener message.
ContainerMessage : command sent that generate the status.

Implemented in org.openmobileis.modules.common.log.client.LogsSynchroListener, org.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener, org.openmobileis.synchro.openmsp.client.OpenMSPDBSyncListener, and org.openmobileis.synchro.openmsp.protocol.test.TestOpenMSSyncListener.

Referenced by org.openmobileis.synchro.openmsp.client.core.OpenMSPSyncMessageFactory.receiveOpenMSPMessage().

void org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener.receiveSyncCommand ContainerMessage  syncContainer,
long  newSyncNumber
throws OpenMSPException
 

Event sent when the sync manager receives Sync command openML messages from the server.

Parameters:
ContainerMessage container : container containing the message
long newSessionID : the session id use for this synchro for this listener message.

Implemented in org.openmobileis.modules.common.log.client.LogsSynchroListener, and org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener.

Referenced by org.openmobileis.synchro.openmsp.client.core.OpenMSPSyncMessageFactory.receiveOpenMSPMessage().


The documentation for this interface was generated from the following file:
Generated on Wed Dec 14 21:05:40 2005 for OpenMobileIS by  doxygen 1.4.4