createDefaultGenerateGeodatabaseParameters method

Future<GenerateGeodatabaseParameters> createDefaultGenerateGeodatabaseParameters(
  1. {required Geometry extent}
)

Creates default parameters to generate and download a geodatabase using the GenerateGeodatabaseJob.

This populates the parameters with values that match the feature service. For example, if the service does not support SyncModel.layer then SyncModel.geodatabase will be used and all layers from the service will be included. Attachments are included by default, but related tables/layers are not included. Output features are in the spatial reference of the given extent.

Parameters:

  • extent — The extent of the data to be included in the generated geodatabase. Must be non-null.

Return Value: Returns a set of parameters that can be used to generate a geodatabase. The returned Future contains a GenerateGeodatabaseParameters.

Implementation

Future<GenerateGeodatabaseParameters>
    createDefaultGenerateGeodatabaseParameters({required Geometry extent}) {
  final taskHandle = _withThrowingErrorHandler((errorHandler) {
    return runtimecore
        .RT_GeodatabaseSyncTask_createDefaultGenerateGeodatabaseParametersAsync(
            _handle, extent._handle, errorHandler);
  });
  return taskHandle.toFuture(
      (element) => element.getValueAsGenerateGeodatabaseParameters()!);
}