我似乎无法弄清楚为什么这个功能不会触发
func locationManager(manager:CLLocationManager, didEnterRegion region:CLRegion) {
println("here")
var localNotification:UILocalNotification = UILocalNotification()
localNotification.alertAction = "Grab your bags "
UIApplication.sharedApplication().scheduleLocalNotification(localNotification)
我认为这是在进入或离开被监控的区域时触发的,这就是我监控我的区域的方式
var wholeFoodsRegion = CLCircularRegion(center: wholeFoods, radius: CLLocationDistance(33.0), identifier:"wholeFoods")
然后将其放入数组中并像这样监视
for(var i = 0; i < regions.count; i++){
locationManager.startMonitoringForRegion(regions[i])
}
我如何在进入某个区域时触发该功能