concept Geocoder in category android

This is an excerpt from Manning's book Android in Action, Third Edition.
Beyond the buoy application requirements, you’ll also write a few samples for working with the Geocoder class. This class allows you to map between a GeoPoint (latitude and longitude) and a place (city or postal code) or address. This utility doesn’t help much on the high seas but does benefit many other apps.
The Android documentation describes geocoding as converting a “street address or other description of a location” into latitude and longitude coordinates. Reverse geocoding is the opposite—converting latitude and longitude into an address. To accomplish this, the Geocoder class makes a network call to a web service.
![]()
You create a Geocoder by constructing it with the Context of your application
. You then use a Geocoder to either convert String instances that represent place names into Address objects with the getFromLocationName() method
or convert latitude and longitude coordinates into Address objects with the getFromLocation() method
.
. You then use a Geocoder to either convert String instances that represent place names into Address objects with the getFromLocationName() method
or convert latitude and longitude coordinates into Address objects with the getFromLocation() method
.