Check if provided location info from fused location provider is from GPS

一个人想着一个人 提交于 2019-12-11 18:12:41

问题


We are using fused location provider and if I query location.getProvider() on the location I'm receiving it returns fused. I would like to check whether the fused provider used GPS or Wifi or both for the location it gave me. is this possible? how?


回答1:


The fused provider does not provide you with the specific location provider it only returns fused as you said, if you want to listen for a specific provider you need to use the old LocationManager



来源:https://stackoverflow.com/questions/25558761/check-if-provided-location-info-from-fused-location-provider-is-from-gps

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!