iOS Significant-Change Location 事件不会每 15 分钟更新一次应用

iOS Significant-Change Location event doesn't update the app every 15 mins

根据 documentation:

Significant-change location updates wake the system and your app once every 15 minutes, at minimum, even if no location changes have occurred.

但它并没有像描述的那样工作...

在我的 Xamarin.iOS 项目中,我使用

_locationManager = new CLLocationManager
{
    PausesLocationUpdatesAutomatically = false,
};
_locationManager.StartMonitoringSignificantLocationChanges();

*我在这里跳过了所有权限检查和 plist 配置。更新工作正常,应用程序接收更新,但仅在真正移动的情况下,而不是每 15 分钟一次:如果设备没有移动,可能需要几个小时。

我也看到了 ,但即使应用程序已终止或后台运行,我也需要这些更新。

根据 a reply by an Apple staff member to this thread on the Apple developer forums,文档与您、该线程的原始发布者以及我本人正在观察的内容之间可能存在差异(即与文档中的内容相比,可能没有每 15 分钟更新一次)。

请注意文档中的措辞:“至少每 15 分钟一次”。我们似乎都将“最小”解释为最小频率(即每 15 分钟一次,或每 15 分钟两次,或更多)。但它也可以理解为最小时间间隔(即每 15 分钟,或每 30 分钟或更长时间)。它不保证更新的频率,而是设定更新 不频繁 的预期。文档没有错,但肯定有多种解释。

重要的是苹果工作人员在回复中所说的:

[…] simply using [significant location change] does not guarantee that your app will be resumed as [sic] some periodic rate.

PS。对于那些可以对文档做些什么的人:rdar://30345408(不是我的)