android - 如何从 Windows Phone 8 中的特定提供商获取位置信息?

标签 android windows-phone-8 geolocation

由于 Windows Phone 8 使用不同的提供程序(如网络、WiFi、GPS)来获取位置。是否可以专门从指定的提供商处获取位置?具体来说,如果我只需要来自 GPS 的位置,我应该使用哪个 API?

在 Android 中,可以从特定提供商处找到位置,在 WP8 中寻找相同的功能。

How to use the .NET Location API for Windows Phone 8

The Microsoft Location Service allows you to create location-aware applications for Windows Phone. The service obtains location data from multiple sources such as GPS, Wi-Fi, and cellular. It can use one or more of these sources to deduce the location of the Windows Phone, balancing performance with power utilization depending on an application’s needs.

最佳答案

使用哪种方法(GPS、Wi-Fi 和蜂窝网络)取决于为地理定位器设置的属性。 DesiredAccuracyDesiredAccuracyInMeters是这里的关键。当 DesiredAccuracy 设置为高时,它将使用设备上可用的最佳方式。同样,当 DesiredAccuracyInMeters 小于 100 时。

请注意,当 DesiredAccuracy 设置为 high 时地理定位器将:

Deliver the most accurate report possible. This includes using services that might charge money, or consuming higher levels of battery power or connection bandwidth. An accuracy level of High may degrade system performance and should be used only when necessary.

关于android - 如何从 Windows Phone 8 中的特定提供商获取位置信息?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22140432/

相关文章:

android - 是否可以从应用程序外部识别单击的 View 及其索引号?

javascript - Windows Phone 8 Javascript Canvas 不在整个页面上

windows-phone-8 - Windows Phone 8 中的快速应用程序恢复问题

java - 当 Activity 屏幕首次在 Android Studio 上加载时,如何在隐藏背景中发送带有当前位置数据的 SMS 文本消息?

java - 如何在没有互联网连接的情况下获取网络提供的日期和时间?

android - Jetpack 撰写 : Content color of TabRow

java - 选中复选框时如何将项目移动到最后一个位置? (回收 View ,ViewHolder)

c# - Windows Phone 8 推送通知推送 channel 总是创建新的 channel uri

javascript - 浏览器中的地理定位适用于 1.6 (Gears) 但不适用于 2.0 (HTML5/W3C)

javascript - navigator.geolocation.getCurrentPosition 在 android google chrome 上不起作用