Package com.massifmaps.geocoding
Class ReverseGeocodingService
java.lang.Object
com.massifmaps.geocoding.ReverseGeocodingService
- Direct Known Subclasses:
MapBoxOnlineReverseGeocodingService,MultiOSMOfflineReverseGeocodingService,OSMOfflineReverseGeocodingService,PackageManagerReverseGeocodingService,PeliasOnlineReverseGeocodingService,TomTomOnlineReverseGeocodingService
An abstract base class for reverse geocoding services.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionCalculates matching addresses from the specified reverse geocoding request.Returns the language of the expected results.voidsetLanguage(String lang) Sets the language of the expected results.
-
Constructor Details
-
ReverseGeocodingService
protected ReverseGeocodingService()The default constructor.
-
-
Method Details
-
getLanguage
Returns the language of the expected results.- Returns:
- The language of the expected results. As ISO 639-1 code or empty string.
-
setLanguage
Sets the language of the expected results.- Parameters:
lang- The language to use as ISO 639-1 code. Empty string can be used for default language.
-
calculateAddresses
Calculates matching addresses from the specified reverse geocoding request.- Parameters:
request- The reverse geocoding request to use.- Returns:
- The list of matching geocoding results, sorted by descending ranks.
- Throws:
Exception- If IO error occured during the calculation.IOException
-