setExternalDataSource static method

GemError setExternalDataSource(
  1. DataSource dataSource
)

Configures a custom external data source for providing position samples.

Use this to supply positions from a simulation, log file, or external hardware. The provided DataSource will become the active source for subsequent calls to position, improvedPosition and any registered listeners. Remember to call DataSource.start if the source requires an explicit start.

Parameters

  • dataSource: The DataSource instance to set as the active source.

Returns

Also see:

Implementation

static GemError setExternalDataSource(final DataSource dataSource) {
  final OperationResult resultString = staticMethod(
    'PositionService',
    'setExternalDataSource',
    args: dataSource.pointerId,
  );
  return GemErrorExtension.fromCode(resultString['gemApiError']);
}