org.openmobileis.synchro.openmsp.client.core.test
Class TestSynchroListener

java.lang.Object
  extended byorg.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener
      extended byorg.openmobileis.synchro.openmsp.client.core.test.TestSynchroListener
All Implemented Interfaces:
OpenMSPSyncListener

public final class TestSynchroListener
extends DefaultOpenMSPSyncListener

Title: OpenMobileIS project source
Description:

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

Field Summary
 
Fields inherited from class org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener
ADD_ERROR_MESSAGE, DELETE_ERROR_MESSAGE, ITEM_ERROR_MESSAGE, SYNC_ERROR_MESSAGE, SYNC_UNAUTHORIZED_MESSAGE, UPDATE_ERROR_MESSAGE
 
Fields inherited from interface org.openmobileis.synchro.openmsp.client.OpenMSPSyncListener
SYNCHRO_FAILLED, SYNCHRO_OK
 
Constructor Summary
TestSynchroListener(java.lang.String name)
           
 
Method Summary
 void endSync()
          Fire this event once the current synchro is ended
protected  JournalLogRenderer getJournalLogRenderer()
           
 java.lang.String getSyncName()
          Return the name used to identiy the of the listener in the synchro processus.
 void notifyFailure()
           
 void receiveGetCommand(ContainerMessage getContainer, long newSyncNumber)
          Event sent when the sync manager receives GET command openML messages from the server
 void receiveMapCommand(ContainerMessage mapContainer)
          Event sent when the sync manager receives MAP command openML messages from the server
 void receiveResultCommand(ContainerMessage resultContainer, ContainerMessage initialCommand)
          Event sent when the sync manager receives RESULT openML messages from the server
 void receiveStatusCommand(Status statusCommande, ContainerMessage initialCommand)
          Event sent when the sync manager receives STATUS openML messages from the server
 void sendData(Message message)
          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.
 void startSync(int synchroType)
           
 
Methods inherited from class org.openmobileis.synchro.openmsp.client.DefaultOpenMSPSyncListener
addCredentialToCommand, equals, getSynchroStatus, hashCode, initListener, isSyncOK, notifySynchroFailure, receiveAddCommand, receiveDeleteCommand, receiveGetCommand, receiveReplaceCommand, receiveSyncCommand, receiveSyncItem, setSynchroStatus, startSync
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestSynchroListener

public TestSynchroListener(java.lang.String name)
Method Detail

sendData

public void sendData(Message message)
              throws OpenMSPException
Description copied from interface: OpenMSPSyncListener
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.

Throws:
OpenMSPException

getSyncName

public java.lang.String getSyncName()
Description copied from interface: OpenMSPSyncListener
Return the name used to identiy the of the listener in the synchro processus. This name correspond to the source in the OpenMS protocol.


notifyFailure

public void notifyFailure()

startSync

public void startSync(int synchroType)
               throws OpenMSPException
Throws:
OpenMSPException

endSync

public void endSync()
             throws OpenMSPException
Description copied from interface: OpenMSPSyncListener
Fire this event once the current synchro is ended

Specified by:
endSync in interface OpenMSPSyncListener
Overrides:
endSync in class DefaultOpenMSPSyncListener
Throws:
OpenMSPException

receiveMapCommand

public void receiveMapCommand(ContainerMessage mapContainer)
                       throws OpenMSPException
Event sent when the sync manager receives MAP command openML messages from the server

Specified by:
receiveMapCommand in interface OpenMSPSyncListener
Overrides:
receiveMapCommand in class DefaultOpenMSPSyncListener
Throws:
OpenMSPException

receiveGetCommand

public void receiveGetCommand(ContainerMessage getContainer,
                              long newSyncNumber)
                       throws OpenMSPException
Event sent when the sync manager receives GET command openML messages from the server

Throws:
OpenMSPException

receiveResultCommand

public void receiveResultCommand(ContainerMessage resultContainer,
                                 ContainerMessage initialCommand)
                          throws OpenMSPException
Event sent when the sync manager receives RESULT openML messages from the server

Specified by:
receiveResultCommand in interface OpenMSPSyncListener
Overrides:
receiveResultCommand in class DefaultOpenMSPSyncListener
Throws:
OpenMSPException

receiveStatusCommand

public void receiveStatusCommand(Status statusCommande,
                                 ContainerMessage initialCommand)
                          throws OpenMSPException
Event sent when the sync manager receives STATUS openML messages from the server

Throws:
OpenMSPException

getJournalLogRenderer

protected JournalLogRenderer getJournalLogRenderer()
Overrides:
getJournalLogRenderer in class DefaultOpenMSPSyncListener


Copyright 2006 OpenMobileIS. All Rights Reserved.