Android Geocoder not detect highway / interstate?

I use getThoroughwayfare () to get street names, but when null is returned on the highway / interstate method. I could not find another method that could detect interstate relations. Has anyone been able to successfully discover interstate relations?

thank

+3
source share
1 answer

Ok, this is a pretty old question, but I think I'm in charge of someone else.

I also need to get information about whether I was at the interstate or not, and Geocoder did not help. So I came across Google geocode apithat which gives a lot of information.

eg

LatLng: 39.249121, -122.182131

And Url will be:

https://maps.googleapis.com/maps/api/geocode/json?latlng=39.249121,-122.182131&sensor=false

Sensor

is true if you are sending from a mobile and false if using a browser.

Now you can open the link and check the detailed answer for yourself, in those objects jsonyou receive type = route, and you will receive as the road in which you are. I-5short_name

+3
source

All Articles