我有两个CLLocation对象,我希望以漂亮漂亮的格式显示它们之间的距离.像"22英尺","58码"或"2.3英里"
CLLocation *location1 = [[CLLocation alloc] initWithLatitude:42.333297 longitude:-71.588858];
CLLocation *location2 = [[CLLocation alloc] initWithLatitude:42.353297 longitude:-71.578858];
float target = [location1 getDistanceFrom:location2];
Run Code Online (Sandbox Code Playgroud)
基本上,iOS库中有什么东西可以将距离转换为漂亮的字符串,还是我必须手动执行此操作?