草庐IT

field_region

全部标签

iOS : Region monitoring and battery usage

我想在iOS中使用区域监控,用于基于位置的警报/计算。我担心它会耗尽电池电量。我在iOSreference上搜索它,但找不到任何证据。无论区域监控(即每分钟左右扫描一次......),该服务是否始终可用,或者我应该改用“重大位置更改”API?更新:因此,电池使用情况并不显着。其实还不错。想收到一些关于在模式(区域/标准)之间切换的建议。 最佳答案 在检查了将近2周后,我可以看出区域监控并没有显着耗尽电池电量。事实上,它肯定会成为iOS5中的一项主动服务,因为内置的提醒应用程序将使用24/7全天候区域监控。

android - Kotlin 错误 : Dagger does not support injection into private fields

我在kotlinActivityViewPager中使用,我希望在KotlinFragment中使用Dagger注入(inject)。我有错误:Dagger不支持注入(inject)私有(private)字段。在JavaFragment中,Dagger注入(inject)工作。为什么我不能在kotlinfaragment中注入(inject)dagger?在我的kotlinActivity中mPagerAdapter=object:FragmentPagerAdapter(supportFragmentManager){privatevalmFragments=arrayOf(Kotl

android - Kotlin 错误 : Dagger does not support injection into private fields

我在kotlinActivityViewPager中使用,我希望在KotlinFragment中使用Dagger注入(inject)。我有错误:Dagger不支持注入(inject)私有(private)字段。在JavaFragment中,Dagger注入(inject)工作。为什么我不能在kotlinfaragment中注入(inject)dagger?在我的kotlinActivity中mPagerAdapter=object:FragmentPagerAdapter(supportFragmentManager){privatevalmFragments=arrayOf(Kotl

ios - 理解 iBeacon 数据 : the power field and other bytes

我是蓝牙系统的新手,我正在尝试了解用于新Apple技术的数据:iBeacon。已经有一些很好的答案解释了它是如何工作的,我一直在阅读我能找到的所有内容(尤其是蓝牙规范)。尽管如此,我还是遗漏了一些要点,我将首先举个例子:(我正在使用SetAdvertisingDataCommand,它在这里遗漏了OGF之前的hcitoolcmd)0x080x00081E02011A1AFF4C000215E2C56DB5DFFB48D2B060D0F5A71096E000000000C500我会在这里列出我不明白的或找到的信息。有没有关于OGF的任何信息(这里是0x08)?我知道它代表OpCodeGr

iphone - (iOS)通过locationManager的多个通知:didExitRegion: when exiting a region

我正在开发一个使用CLLocationManager区域监视的基于位置的应用程序。我使用的是单个CLLocationManager和单个委托(delegate)(它们在启动时在主应用程序委托(delegate)中设置),并且我注意到退出时经常收到对我的委托(delegate)的多次调用(在locationManager:didExitRegion:上)受监控的区域-通常有两个电话,但有时还会更多。有没有其他人经历过这种情况,或有任何想法可能出什么问题?我在应用程序委托(delegate)实例化的类中实例化CLLocationManager,如下所示:_locationManager=[

iOS 8 今日扩展 : Is it possible to add editable text field?

我正在尝试创建一个简单的TodayExtension。我能够添加一个标签,其中的值可以通过主应用程序更新。现在,我正在探索通过扩展更新主应用程序中的值的可能性。但是,当我尝试添加文本字段时,我无法输入任何内容。这是扩展的限制吗?如果没有,你能指导我如何完成这个吗?非常感谢! 最佳答案 不幸的是,这是一个限制。Apple的扩展编程指南中说:BecauseuserinteractionwithTodaywidgetsisquickandlimited,youshoulddesignasimple,streamlinedUIthathig

iphone - CLLocationManager 地理编码地址字符串 :inRegion not working to constrain region (ios5)

我正在尝试使用iOS5中新的CLLocationManagerAPI来使用(转发)地理编码,但运气不佳。我正在根据当前位置指定一个区域,但它会给我世界另一端的结果。//CLLocation*currentlocissettothecurrentlocationwhenIgetinhere()CLRegion*region=[[CLRegionalloc]initCircularRegionWithCenter:[currentloccoordinate]radius:5000/*meters*/identifier:@"Youarehere"];//Regionisnow:(ident

java - Android ViewGroup 崩溃 : Attempt to read from field 'int android.view.View.mViewFlags' on a null object reference

我们发现了几个后端日志监控报告的此类崩溃案例。崩溃似乎与特定的UX故障无关。而且从报告中看,没有迹象表明我们自己的类(class)是如何参与的(没有任何我们的类(class)名称的迹象)。以下是典型崩溃的示例:java.lang.NullPointerException:Attempttoreadfromfield'intandroid.view.View.mViewFlags'onanullobjectreferenceatandroid.view.ViewGroup.dispatchDraw(ViewGroup.java:3357)atandroid.view.View.updat

java - Android ViewGroup 崩溃 : Attempt to read from field 'int android.view.View.mViewFlags' on a null object reference

我们发现了几个后端日志监控报告的此类崩溃案例。崩溃似乎与特定的UX故障无关。而且从报告中看,没有迹象表明我们自己的类(class)是如何参与的(没有任何我们的类(class)名称的迹象)。以下是典型崩溃的示例:java.lang.NullPointerException:Attempttoreadfromfield'intandroid.view.View.mViewFlags'onanullobjectreferenceatandroid.view.ViewGroup.dispatchDraw(ViewGroup.java:3357)atandroid.view.View.updat

iOS 7 核心位置 : region monitoring fails on the first time after location services are authorised

我使用CoreLocation在我的应用程序上发现了一个奇怪的行为。我正在使用区域监控功能,但在授权位置服务(通过弹出窗口或设置->位置服务)后,区域监控失败(操作无法完成。kCLErrorDomain错误5.)。如果我关闭应用程序并重新启动(因此已经获得授权),一切都会按预期进行。我的代码如下所示:-(void)initializeLocationServices{NSLog(@"Startedlocationservices");locationManager=[[CLLocationManageralloc]init];locationManager.delegate=self;