3

I have a real quick question. As far as I know the Geolocator package uses the Android FusedLocationProviderClient to access the users location. Does this client use all the permitted opportunities to get the location (like gps,wlan,mobile networks...) or does this only use the gps data?

All together: How does the FusedLocationProviderClient get the data for the users location?

Thanks for the answer.

Curious99
  • 378
  • 2
  • 12
  • Not sure, but I think it depends on what the user has set in the settings and whether power saving mode is on? – JaffaKetchup Aug 05 '21 at 10:21
  • the goole play location service periodically store the user location either via mobile network , wifi or gps whichever is present . however it might not always be up to date or most accurate – Akash Pal Aug 05 '21 at 10:23

1 Answers1

1

The fused location provider manages the underlying location technologies, such as GPS and Wi-Fi, and provides a simple API that you can use to specify the required quality of service. For example, you can request the most accurate data available, or the best accuracy possible with no additional power consumption

We need not explicitly choose either GPS or Network location Provider, as the “Fused Location Provider” automatically chooses the underlying technology and gives the best location as per the need.

REF : https://developers.google.com/location-context/fused-location-provider/

So, regaring you question about the accuracy of the location it totally depends whethere the location was enabled and the fusedLocation stored it for furture use.

Akash Pal
  • 1,055
  • 8
  • 15
  • So me requesting the most accurate data and the user turning on gps,wifi,.. leads to the most accurate result? – Curious99 Aug 05 '21 at 11:28
  • 1
    yes make sure your app has the location access and on splash creen just request gps location if not already present in fusedLoactionService – Akash Pal Aug 05 '21 at 12:07