Class Continent


public final class Continent extends AbstractNamedRecord

Contains data for the continent record associated with an IP address.

Do not use any of the continent names as a database or map key. Use the value returned by AbstractNamedRecord.getGeoNameId() or getCode() instead.

  • Constructor Details

    • Continent

      public Continent()
      Constructs an instance of Continent with no data.
    • Continent

      public Continent(List<String> locales, String code, Long geoNameId, Map<String,String> names)
      Constructs an instance of Continent.
      Parameters:
      locales - The locales to use.
      code - A two character continent code like "NA" (North America) or "OC" (Oceania).
      geoNameId - The GeoName ID for the continent.
      names - A map from locale codes to the continent names.
    • Continent

      public Continent(Continent continent, List<String> locales)
      Constructs an instance of Continent.
      Parameters:
      continent - The Continent object to copy.
      locales - The locales to use.
  • Method Details

    • getCode

      public String getCode()
      Returns:
      A two character continent code like "NA" (North America) or "OC" (Oceania).