|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
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.
Field Summary | |
static int |
SYNCHRO_FAILLED
|
static int |
SYNCHRO_OK
|
Method Summary | |
void |
endSync()
Fire this event once the current synchro is ended |
int |
getSynchroStatus()
Return the synchro status of the listener. |
java.lang.String |
getSyncName()
Return the name used to identiy the of the listener in the synchro processus. |
void |
initListener()
Call during listener registering. |
boolean |
isSyncOK()
return true if the synchronisation is OK for the listener. |
void |
notifySynchroFailure()
The listener is called if the syncML command processing failed |
void |
receiveGetCommand(Credential cred,
ContainerMessage replaceContainer,
long newSyncNumber)
Call when the server answer container contains a GET command. |
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 |
receiveSyncCommand(ContainerMessage syncContainer,
long newSyncNumber)
Event sent when the sync manager receives Sync command 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(Credential cred,
SynchroDescriptor synchrodescriptor)
Fire this event once a synchro is starting |
Field Detail |
public static final int SYNCHRO_OK
public static final int SYNCHRO_FAILLED
Method Detail |
public void sendData(Message message) throws OpenMSPException
OpenMSPException
public java.lang.String getSyncName()
public void notifySynchroFailure()
public int getSynchroStatus()
Status
public boolean isSyncOK()
public void startSync(Credential cred, SynchroDescriptor synchrodescriptor) throws OpenMSPException
OpenMSPException
public void endSync() throws OpenMSPException
OpenMSPException
public void receiveSyncCommand(ContainerMessage syncContainer, long newSyncNumber) throws OpenMSPException
OpenMSPException
public void receiveMapCommand(ContainerMessage mapContainer) throws OpenMSPException
OpenMSPException
public void receiveResultCommand(ContainerMessage resultContainer, ContainerMessage initialCommand) throws OpenMSPException
OpenMSPException
public void receiveStatusCommand(Status statusCommande, ContainerMessage initialCommand) throws OpenMSPException
OpenMSPException
public void receiveGetCommand(Credential cred, ContainerMessage replaceContainer, long newSyncNumber) throws OpenMSPException
OpenMSPException
public void initListener() throws OpenMSPException
ServiceException
OpenMSPException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |