How to know when all addresses have been geocoded
In the Google Maps API, multiple calls are google.maps.ClientGeocoder.getLatLng(address, callback)
not guaranteed in any order. What is an elegant way to determine that all addresses have been geocoded given an array of addresses?
Should I just calculate based on the length of the array and execute the code in the callback only if the countdown reaches zero, or is there a better way to do this in the Google Maps API?
thanks
+1
a source to share