The SyncGeodatabaseJob synchronizes changes between a local geodatabase and its sync-enabled ArcGIS feature service. More...
Header: | #include <SyncGeodatabaseJob.h> |
Since: | Esri::ArcGISRuntime 100.0 |
Inherits: | Esri::ArcGISRuntime::Job |
Public Functions
virtual | ~SyncGeodatabaseJob() override |
Esri::ArcGISRuntime::GeodatabaseDeltaInfo * | geodatabaseDeltaInfo() const |
QList<Esri::ArcGISRuntime::SyncLayerResult *> | result() const |
Detailed Description
To make a SyncGeodatabaseJob, use the GeodatabaseSyncTask as follows:
- Construct and load the GeodatabaseSyncTask with the Geodatabase::serviceUrl.
- Obtain the default SyncGeodatabaseParameters for the geodatabase by calling GeodatabaseSyncTask::createDefaultSyncGeodatabaseParametersAsync(Esri::ArcGISRuntime::Geodatabase*).
- Modify the SyncGeodatabaseParameters as required. For example, specify the synchronization direction.
- Use the SyncGeodatabaseParameters to create a SyncGeodatabaseJob by calling GeodatabaseSyncTask::syncGeodatabase(const Esri::ArcGISRuntime::SyncGeodatabaseParameters&, Esri::ArcGISRuntime::Geodatabase*)).
Start the SyncGeodatabaseJob and monitor progress. On completion, examine the SyncLayerResult from the result to determine whether the synchronization was successful.
Relevant samples:
- Edit and sync features: Synchronize offline edits with a feature service.
See also GenerateGeodatabaseJob.
Member Function Documentation
[override virtual]
SyncGeodatabaseJob::~SyncGeodatabaseJob ()
Destructor.
[since Esri::ArcGISRuntime 100.10]
Esri::ArcGISRuntime::GeodatabaseDeltaInfo *SyncGeodatabaseJob::geodatabaseDeltaInfo () const
Returns information on geodatabase upload and download delta files.
When SyncGeodatabaseParameters::isKeepGeodatabaseDeltas is set to true
, this property provides information about the synced geodatabase along with the paths to its uploaded and downloaded deltas.
Delta geodatabases allow you to troubleshoot sync problems - for example by inspecting the changes they contain or sending the file to the system administrator for the feature service.
This property will be set even if the job fails. If SyncGeodatabaseParameters::isKeepGeodatabaseDeltas is false
, this property will be nullptr
.
This function was introduced in Esri::ArcGISRuntime 100.10.
QList<Esri::ArcGISRuntime::SyncLayerResult *> SyncGeodatabaseJob::result() const
Returns the list of SyncLayerResult objects from this job.