Вопрос

I am looking for a "simple" way to implement offline geocoding in an Android application. Any suggestions how this could be done?

As part of an academic project, I need to be able to get an address from coordinates using offline reverse geocoding. It is essential that this is done offline (compared to Nominatim). More over I will use only sub-regions (France, England, etc.). I need it only for testing purposes and PoC(Proof of Concept) so I am looking for something easy to implement. Currently I am using "GeocoderNominatim" from osmbonuspack (online service) so extending that for offline use is preferable.

I am familiar with application such as OsmAnd (Open-source) which do that but are not structured as libraries. Implementing the aforementioned functionality following their design will be a huge overhead compared to the testing I want to do. However, it is still an option if there is no other way.

PS: I was not able to find a proper answer to my particular case in previous "Questions"

Это было полезно?

Решение

AFAIK there is no "simple" way (here: a ready made lib with out of the box data packs) to do that stuff on Android.

As you say there is Nominatim but that service wasn't designed with mobile devices/offline ability in mind and needs a lot of ressources and isn't available as android package. There are just very few libs with offline ability and even less are available on Android.

If this is just a prototype, I highly recommend to use an external solution as OsmAnd or Navit and just invoke them externally. Othewise you can spend > 2 weeks to create a own solution that just can lookup for streetnames and works on mobile devices, but I guess that isn't the main goal of your research ;)

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top