public class MobileSyncProcessor extends SyncProcessor
env, envImpl, processorName
Constructor and Description |
---|
MobileSyncProcessor(Environment env,
java.lang.String processorName,
MobileConnectionConfig connectionConfig)
Creates a SyncProcessor for Oracle Mobile Server.
|
Modifier and Type | Method and Description |
---|---|
SyncDataSet |
addDataSet(java.lang.String dataSetName,
java.util.Collection<SyncDatabase> databases)
Adds a data set that is managed by this processor.
|
void |
cancelSync()
Cancels a sync operation being performed in another thread.
|
MobileConnectionConfig |
getConnectionConfig()
Returns the connection configuration.
|
java.util.Map<java.lang.String,SyncDataSet> |
getDataSets()
Returns all SyncDataSets that are managed by this processor.
|
void |
removeDataSet(java.lang.String dataSetName)
Removes a data set that is managed by this processor.
|
void |
setConnectionConfig(MobileConnectionConfig connectionConfig)
Changes the connection configuration.
|
void |
sync(ExportConfig exportConfig,
ImportConfig importConfig,
java.lang.String... dataSetName)
Performs a sync operation for the specified SyncDataSets.
|
void |
syncAll(ExportConfig exportConfig,
ImportConfig importConfig)
Performs a sync operation for all SyncDataSets managed by this
processor.
|
getEnvironment, getName, getSyncDB, openChangeReader, readChangeSetData, readProcessorMetadata, readProcessorTxnData, registerDataSet, setAddHook, setRemoveHook, unregisterDataSet, writeChangeSetData, writeProcessorMetadata, writeProcessorTxnData
public MobileSyncProcessor(Environment env, java.lang.String processorName, MobileConnectionConfig connectionConfig)
public MobileConnectionConfig getConnectionConfig()
public void setConnectionConfig(MobileConnectionConfig connectionConfig)
public SyncDataSet addDataSet(java.lang.String dataSetName, java.util.Collection<SyncDatabase> databases)
SyncProcessor
After calling this method, all changes to the JE databases in the data set will be tracked by JE, so they can be exported to the external system during a sync operation. The tracking of changes in the external system, if any, is defined by the SyncProcessor subclass.
The user must ensure that no transactions for the databases in the data set are active during the call to this method. If transactions are active, the results of the first sync operation with respect to these transactions are undefined, and the sync is unlikely to succeed.
Normally, each database in a newly added data set should be initially empty or non-existent. If a database is non-empty, the user must ensure that the records in the database are present in the external system.
addDataSet
in class SyncProcessor
SyncProcessor.addDataSet(java.lang.String, java.util.Collection<com.sleepycat.je.sync.SyncDatabase>)
public void removeDataSet(java.lang.String dataSetName)
SyncProcessor
removeDataSet
in class SyncProcessor
public java.util.Map<java.lang.String,SyncDataSet> getDataSets()
SyncProcessor
getDataSets
in class SyncProcessor
SyncProcessor.getDataSets()
public void syncAll(ExportConfig exportConfig, ImportConfig importConfig)
SyncProcessor
syncAll
in class SyncProcessor
public void sync(ExportConfig exportConfig, ImportConfig importConfig, java.lang.String... dataSetName)
SyncProcessor
sync
in class SyncProcessor
public void cancelSync()
SyncProcessor
cancelSync
in class SyncProcessor
Copyright (c) 2004-2012 Oracle. All rights reserved.