ios - Completion block for GPS coordinates -


as apps enables user location every , then, use ability location in completion block. @ moment i've set notification using

nsnotificationcenter.defaultcenter().postnotificationname("functiontorun", object: nil)  

when user request location, run function

func getlocation() -> cllocation {     locationmanager.requestlocation()     return location } 

however updating location can take while, , returning latest location, can implement in completion block, can actual location?

cllocationmanager doesn't work way use cllocationmanager-blocks cocoa pod functionality. read through documentation make sure behaves way expect to.


Comments

Popular posts from this blog

serialization - Convert Any type in scala to Array[Byte] and back -

matplotlib support failed in PyCharm on OSX -

python - Matplotlib: TypeError: 'AxesSubplot' object is not callable -