Package com.maxmind.geoip2.record
Class Continent
- java.lang.Object
-
- com.maxmind.geoip2.record.AbstractRecord
-
- com.maxmind.geoip2.record.AbstractNamedRecord
-
- com.maxmind.geoip2.record.Continent
-
public final class Continent extends AbstractNamedRecord
Contains data for the continent record associated with an IP address.
This record is returned by all the end points.
Do not use any of the continent names as a database or map key. Use the value returned by
AbstractNamedRecord.getGeoNameId()
orgetCode()
instead.
-
-
Constructor Summary
Constructors Constructor Description Continent()
Continent(Continent continent, List<String> locales)
Continent(List<String> locales, String code, Integer geoNameId, Map<String,String> names)
Continent(List<String> locales, String code, Long geoNameId, Map<String,String> names)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getCode()
-
Methods inherited from class com.maxmind.geoip2.record.AbstractNamedRecord
getGeoNameId, getName, getNames
-
Methods inherited from class com.maxmind.geoip2.record.AbstractRecord
toJson, toString
-
-
-
-
Method Detail
-
getCode
public String getCode()
- Returns:
- A two character continent code like "NA" (North America) or "OC" (Oceania). This attribute is returned by all end points.
-
-