beginSynchronize

Sends a message to the Unwired Server to synchronize data between the client and the server. There are two different beginSynchronize APIs, one with no parameters that synchronizes all the groups, and one that takes a list of groups.

The synchronization completes in the background through an asynchronous message exchange with the server. If application code needs to know when the synchronization is complete, a callback handler that implements the onSynchronize method must be registered with the database class.

In RBS, beginSynchronize creates a synchronize request, and puts it in the request queue; the synchronization thread processes the sync request, and does the synchronization automatically in the background. The synchronization thread can combine several synchronization requests and send them to the server. For each synchronization request, a SUPSynchronizationStatus_STARTING status is sent to the onSynchronize user callback function before the synchronization, and a SUPSynchronizationStatus_FINISHING status is sent to onSynchronize after the synchronization.

Syntax

+(void) beginSynchronize[:(SUPObjectList*)synchronizationGroups] [withContext:(NSString*)context]

Parameters

Returns

None.

Examples