I can get the result (like locality
, ISOcountryCode
, etc) by CLGeocoder
's reverseGeocodeLocation:completionHandler:
method successfully.
But how can I match the place with the result?
e.g.: If the city (locality) of result is Hangzhou City
, I can match it simply by using
if ([placemark.locality isEqualToString:@"Hangzhou City"]) {...}
But as you know, there're millions of cities, it's impossible to get the city name one by one and hard code into my app.
So, is there any way to solve this problem? Or does there any framework exist? Or just several files contain countries & cities' name that match the CLGeocoder
's result? Even fuzzy coordinate matching solution is okay (I mean, a city has its own region, and I can determine the city just by coordinate, but I still need to get every city's region area at the moment).
Deployment Target iOS5.0