importDelta static method
- {required Geodatabase geodatabase,
- required Uri inputUri}
Imports a geodatabase delta and applies it to the given geodatabase.
A delta geodatabase contains the changes that have occurred since a mobile replica Geodatabase was last-synchronized with the feature service. See Synchronize Replica for an overview of the delta files used in synchronization. A "download" delta geodatabase contains the online edits that will be imported to the local geodatabase.
The task returned by this method returns an array of SyncLayerResult.
You should not execute more than one sync on a particular geodatabase at the same time. This includes any operations that export or import deltas from the local Geodatabase, which are:
- GeodatabaseSyncTask.exportDelta
- GeodatabaseSyncTask.importDelta
- SyncGeodatabaseJob
- OfflineMapSyncJob
Parameters:
geodatabase
— The geodatabase to apply a delta to.inputUri
— The path and filename to import the delta from.
Return Value: A task that imports a geodatabase delta and has an element
type of List
. The array elements are of type SyncLayerResult.
Implementation
static Future<List<SyncLayerResult>> importDelta(
{required Geodatabase geodatabase, required Uri inputUri}) {
_initializeArcGISEnvironmentIfNeeded();
final coreInputUri = _CString(inputUri.toFilePath());
final taskHandle = _withThrowingErrorHandler((errorHandler) {
return runtimecore.RT_GeodatabaseSyncTask_importDeltaAsync(
geodatabase._handle, coreInputUri.bytes, errorHandler);
});
return taskHandle.toFuture((element) => element.getValueAsList()!);
}