stopAfterElapsedMinutes property

int? stopAfterElapsedMinutes
getter/setter pair

Automatically BackgroundGeolocation.stop tracking after x minutes.

The plugin can optionally automatically BackgroundGeolocation.stop after some number of minutes elapses after the BackgroundGeolocation.start method was called.

BackgroundGeolocation.ready(Config(
  stopAfterElapsedMinutes: 30
)).then((State state) {
  BackgroundGeolocation.start();  // <-- plugin will automatically #stop in 30 minutes
});

Implementation

int? stopAfterElapsedMinutes;