Class MultiOSMOfflineReverseGeocodingService

java.lang.Object
com.massifmaps.geocoding.ReverseGeocodingService
com.massifmaps.geocoding.MultiOSMOfflineReverseGeocodingService

public class MultiOSMOfflineReverseGeocodingService extends ReverseGeocodingService
A reverse geocoding service that uses custom geocoding database files.
Note: this class is experimental and may change or even be removed in future SDK versions.
  • Constructor Details

    • MultiOSMOfflineReverseGeocodingService

      public MultiOSMOfflineReverseGeocodingService() throws IOException
      Constructs a new instance of the MultiOSMOfflineReverseGeocodingService given package manager instance.
      Throws:
      IOException
  • Method Details

    • getLanguage

      public String getLanguage()
      Description copied from class: ReverseGeocodingService
      Returns the language of the expected results.
      Overrides:
      getLanguage in class ReverseGeocodingService
      Returns:
      The language of the expected results. As ISO 639-1 code or empty string.
    • setLanguage

      public void setLanguage(String lang)
      Description copied from class: ReverseGeocodingService
      Sets the language of the expected results.
      Overrides:
      setLanguage in class ReverseGeocodingService
      Parameters:
      lang - The language to use as ISO 639-1 code. Empty string can be used for default language.
    • calculateAddresses

      public GeocodingResultVector calculateAddresses(ReverseGeocodingRequest request) throws IOException
      Description copied from class: ReverseGeocodingService
      Calculates matching addresses from the specified reverse geocoding request.
      Overrides:
      calculateAddresses in class ReverseGeocodingService
      Parameters:
      request - The reverse geocoding request to use.
      Returns:
      The list of matching geocoding results, sorted by descending ranks.
      Throws:
      IOException
    • add

      public void add(String database)
      Adds a new database.
      Parameters:
      database - The database file patht to be added.
    • remove

      public boolean remove(String database)
      Removes a database.
      Parameters:
      database - The database file patht to be removed.
      Returns:
      True if the database was removed. False otherwise ( database was not found).