LocationClientOptions constructor

LocationClientOptions({
  1. bool isMockEnable = true,
  2. num interval = 2000,
  3. bool isOnceLocation = false,
  4. bool isNeedAddress = true,
  5. bool isWifiScan = true,
  6. LocationMode locationMode = LocationMode.Battery_Saving,
  7. LocationProtocol locationProtocol = LocationProtocol.HTTP,
  8. bool isKillProcess = false,
  9. bool isGpsFirst = false,
  10. num httpTimeOut = 30000,
  11. bool isOffset = true,
  12. bool isLocationCacheEnable = true,
  13. bool isOnceLocationLatest = false,
  14. bool isSensorEnable = false,
  15. num lastLocationLifeCycle = 30000,
  16. GeoLanguage geoLanguage = GeoLanguage.ZH,
  17. bool? isDownloadCoordinateConvertLibrary,
  18. num deviceModeDistanceFilter = 0.0,
  19. AMapLocationPurpose? locationPurpose,
  20. bool isOpenAlwaysScanWifi = true,
  21. num scanWifiInterval = 30000,
  22. num distanceFilter = 0,
  23. bool pausesLocationUpdatesAutomatically = false,
  24. bool allowsBackgroundLocationUpdates = false,
  25. num locationTimeout = 3000,
  26. num reGeocodeTimeout = 3000,
  27. bool locatingWithReGeocode = false,
  28. Set? monitoredRegions,
  29. bool detectRiskOfFakeLocation = false,
})

Implementation

LocationClientOptions({
  this.isMockEnable = true,
  this.interval = 2000,
  this.isOnceLocation = false,
  this.isNeedAddress = true,
  this.isWifiScan = true,
  this.locationMode = LocationMode.Battery_Saving,
  this.locationProtocol = LocationProtocol.HTTP,
  this.isKillProcess = false,
  this.isGpsFirst = false,
  this.httpTimeOut = 30000,
  this.isOffset = true,
  this.isLocationCacheEnable = true,
  this.isOnceLocationLatest = false,
  this.isSensorEnable = false,
  this.lastLocationLifeCycle = 30000,
  this.geoLanguage = GeoLanguage.ZH,
  this.isDownloadCoordinateConvertLibrary,
  this.deviceModeDistanceFilter = 0.0,
  this.locationPurpose, // 可以为空
  this.isOpenAlwaysScanWifi = true,
  this.scanWifiInterval = 30000,
  this.distanceFilter = 0,
  this.pausesLocationUpdatesAutomatically = false,
  this.allowsBackgroundLocationUpdates = false,
  this.locationTimeout = 3000,
  this.reGeocodeTimeout = 3000,
  this.locatingWithReGeocode = false,
  this.monitoredRegions,
  this.detectRiskOfFakeLocation = false,
});