Re: [問題] 有關geofencing的問題

作者: fallenheart (水中落葉)   2014-05-07 10:58:44
※ 引述《chen0404 (沒有暱稱)》之銘言:
: 我想double check當在ios7時, app在background或者not running狀態是不會啟動的?
: 也就是說系統不會幫你偵測你是否進入範圍內,但在ios7.1是可以的?
根據我的經驗,
iOS 6.1 會啟動,iOS 7.1 也會啟動,
我想 iOS 7.0 應該也一樣才對。
: 第二個問題是當app不再background時,根據文件系統會幫你偵測,如果進入區域系統會
: 幫你喚醒(wake up or relaunch in the background)
: 我想問的是系統喚醒的意思是他會delegate didFinishLaunchingWithOptions嗎?
: 假設是的話我是不是只要在重新alloc一遍CLLocationManager?
: ex. if (launchOptions[UIApplicationLaunchOptionsLocationKey]) {
: [self.locationManager startUpdatingLocation];
: }
: 參考文件:
Using Regions to Monitor Boundary Crossings
: 謝謝大大
如果沒有要用到其他東西,
確實可以只 alloc location manager 跟它的 delegate 去做事即可。
作者: chen0404 (沒有暱稱)   2014-05-07 12:39:00
謝謝您的解釋 所以請問我的做法正確嗎?當app沒有再跑時系統會自動monitor是否進入區域內,如果有他會呼叫didFinishLaunchingWithOptions->(自己alloc ma.manager)-> 系統delegate didEnterRegion ??

Links booklink

Contact Us: admin [ a t ] ucptt.com