当前位置: 代码迷 >> Iphone >> ios定位的疑点
  详细解决方案

ios定位的疑点

热度:103   发布时间:2016-04-25 06:15:41.0
ios定位的疑问
MKReverseGeocoder *geoCoder = [[[MKReverseGeocoder alloc] initWithCoordinate:coordinate2D] autorelease];
  geoCoder.delegate = self;
  [geoCoder start];


- (void)reverseGeocoder:(MKReverseGeocoder *)geocoder didFindPlacemark:(MKPlacemark *)placemark
{
  NSString *local=placemark.locality;
  if (local) {
  NSString *address = [NSString stringWithFormat:@"%@ %@ %@ %@ %@%@", 
  placemark.country,
  placemark.administrativeArea,
  placemark.locality,
  placemark.subLocality,
  placemark.thoroughfare,
  placemark.subThoroughfare];
  NSLog(@"经纬度所对应的详细:%@", address);
  }
}


Q:为什么address取到的值都是拼音呢,而不是中文??比如说placemark.country得到的值是China,placemark.administrativeArea得到的值是guangdong。
  相关解决方案