Questions tagged [clgeocoder]

The CLGeocoder class provides services for converting between a coordinate (specified as a latitude and longitude) and the user-friendly representation of that coordinate.

The CLGeocoder class provides services for converting between a coordinate (specified as a latitude and longitude) and the user-friendly representation of that coordinate. A user-friendly representation of the coordinate typically consists of the street, city, state, and country information corresponding to the given location, but it may also contain a relevant point of interest, landmarks, or other identifying information. A geocoder object is a single-shot object that works with a network-based service to look up placemark information for its specified coordinate value.

http://developer.apple.com/library/ios/#documentation/CoreLocation/Reference/CLGeocoder_class

227 questions
0
votes
0 answers

Is it allowed to store the results that are returned from reverseGeocodeLocation() in database?

I was wondering whether it is allowed to store address information that is returned from calling the reverseGeocodeLocation using the CLGeocoder class? In other words, if I would pass lat and long values to the reverseGeocodeLocation and store the…
Andi
  • 8,154
  • 3
  • 30
  • 34
0
votes
1 answer

CLGeocodeCompletionHandler ios swift3

Do any 1 know any changes on swift3?How to fix the following code I m using geococdeAddressString class func getMapByAddress(_ locationMap:MKMapView?, address:String?, title: String?, subtitle: String?) { let geocoder = CLGeocoder() …
Stefan Lam
  • 130
  • 10
0
votes
0 answers

Can I use CLGeocoder apis in android in any possible way

I want to use iOS CLGeocoder apis in android.Is there any possible way to do this because I dont want to use Google Maps geocoding apis? PS:Downvoters,No question is stupid in this world.
Desert Rose
  • 3,376
  • 1
  • 30
  • 36
0
votes
1 answer

Why use CLGeocoder with an array of "placemarks"?

When trying to use CLGeocoder, I got this example from an online tutorial: https://www.appcoda.com/how-to-get-current-location-iphone-user/ - (void)locationManager:(CLLocationManager *)manager didUpdateToLocation:(CLLocation *)newLocation…
Chenya Zhang
  • 463
  • 3
  • 11
  • 22
0
votes
0 answers

How to get all possible location based on given search?

I need to get all possible location from given string, I know its available in Google API, but I want in apple native API. I have tried following 2 codes, but both are return only one location, but need all possible solution for given input. It is…
Ammaiappan
  • 539
  • 3
  • 22
0
votes
1 answer

Missing Argument for Parameter #1 in call using CLGeocoder

I get the error missing argument for parameter #1 in call when trying to call geocodeLocation in the viewDidLoad, this is kind of a random error or im doing something completely wrong? override func viewDidLoad(){ super.viewDidLoad() …
ABlach
  • 17
  • 5
0
votes
1 answer

CLGeoCoder doesn't append placemarks in right order

In my viewDidLoad I have this method which turns a location from Parse into a city and state. The only problem is, is that it appends in the wrong order most of the time. Also the .location I have on the end of the location variable is a custom…
John Doe
  • 1,609
  • 2
  • 13
  • 22
0
votes
1 answer

CLGeocoder rate limited error - alternatives?

So CLGeocoder api to convert a CLLocation object into a proper address reverseGeocodeLocation: . I just noticed as it specifies in the doc that it's rate-limited. A lot of users in our app are seeing the ErrorCode:2 which is due to the rate…
Legolas
  • 12,145
  • 12
  • 79
  • 132
0
votes
0 answers

iOS reverseGeocodeLocation error

I'm trying to get placemark for a location in iOS. I've got the location, but reverseGeocodeLocation: completionHandler: method show me an error. found placemarks: (null); error: Error Domain=kCLErrorDomain Code=2 "(null)" The difference between…
lxmfly123
  • 126
  • 9
0
votes
1 answer

Swift 2 , CLGeocoder() and placemarks

I want to get the address of the GPS signal and I write that code: ` CLGeocoder().reverseGeocodeLocation(userLocation) { (placemarks, error) -> Void in if error != nil { print("Κάτι δεν πήγε καλά με το GPS!") }…
iGermanos
  • 181
  • 1
  • 1
  • 6
0
votes
0 answers

CLGeocoder reverseGeocodeLocation Energy leak issues

I am using a CLGeocoder().reverseGeocodeLocation and when it is ran, I get "very high" energy consumption and a bit of Overhead. Here's my code: if CLLocationManager.authorizationStatus() == .AuthorizedWhenInUse { var currentLatCoord =…
Charles Truluck
  • 961
  • 1
  • 7
  • 28
0
votes
0 answers

When detecting location, get an error message 'fatal error: unexpectedly found nil while unwrapping an Optional value'

Here's my locationManager function, can someone please tell me why I'm getting the error: 'fatal error: unexpectedly found nil while unwrapping Optional value'? func locationManager(manager: CLLocationManager, didUpdateLocations locations:…
SB2015
  • 145
  • 1
  • 1
  • 15
0
votes
3 answers

Swift Completion Handler for Reverse Geocoding

I have been banging my head in order to figure out how to fix this piece of code. Basically I have a piece of code that takes a string cityName and stores the latitude and longitude of it in a global variable and call it in another function right…
0
votes
1 answer

Can't place all annotation from geoCoder on Map

-(void)showLocalRestaurantsWithDishRated:(MKUserLocation *)userLocation { CLGeocoder *geoCoder = [[CLGeocoder alloc] init]; [[RestaurantController sharedInstance] getRestaurantsFromParse:^(NSMutableArray *restaurants) { …
Gama
  • 352
  • 2
  • 16
0
votes
1 answer

iOS Swift - CLGeocoder completionHandler block

I'm trying to parse a location (CLLocation) into a String. func locationToString (currentLocation: CLLocation) -> String? { var whatToReturn: String? CLGeocoder().reverseGeocodeLocation(currentLocation, completionHandler: { (placemarks:…
EladB
  • 326
  • 5
  • 15