|
Golibri | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.golibri.iso.CountryCodes
The CountryCodes class represents all country codes as specified by the ISO 3166 Standard. This class contains the alpha-2, alpha-3 and numeric-3 country codes and provides a means to link the different types of country codes with each other. This happens through the country code records which contain the different types of country codes for a single country. CountryCodes uses the resource file org/golibri/iso/countrycodes.xml. This resource file can be found in the zip-file golibri-resources.zip which comes with each golibri distribution. If needed the XML-file can be updated or changed to serve your own needs. The classes Alpha2CountryCodes, Alpha3CountryCodes and Numeric3CountryCodes all use CountryCodes to verify the existence of certain country codes.
Alpha2CountryCodes,
Alpha3CountryCodes,
Numeric3CountryCodes| Constructor Summary | |
CountryCodes()
|
|
| Method Summary | |
static boolean |
alpha2CountryCodeExists(java.lang.String countryCode)
Verifies if an alpha-2 country code exists. |
static boolean |
alpha3CountryCodeExists(java.lang.String countryCode)
Verifies if an alpha-3 country code exists. |
static boolean |
countryCodeExists(java.lang.String countryCode)
Verifies if a country code exists. |
static Alpha2CountryCode |
getAlpha2CountryCode(java.lang.String countryCode)
Static factory method that creates Alpha2CountryCode objects. |
static Alpha2CountryCode[] |
getAlpha2CountryCodes()
Static method that returns all existing alpha-2 country codes. |
static Alpha3CountryCode |
getAlpha3CountryCode(java.lang.String countryCode)
Static factory method that creates Alpha3CountryCode objects. |
static Alpha3CountryCode[] |
getAlpha3CountryCodes()
Static method that returns all existing alpha-3 country codes. |
static CountryCodeRecord |
getCountryCodeRecord(Alpha2CountryCode alpha2CountryCode)
|
static CountryCodeRecord |
getCountryCodeRecord(Alpha3CountryCode alpha3CountryCode)
|
static CountryCodeRecord |
getCountryCodeRecord(Numeric3CountryCode numeric3CountryCode)
|
static CountryCodeRecord |
getCountryCodeRecord(java.lang.String countryCode)
|
static CountryCodeRecord[] |
getCountryCodeRecords()
|
static Numeric3CountryCode |
getNumeric3CountryCode(int countryCode)
Static factory method that creates Numeric3CountryCode objects. |
static Numeric3CountryCode[] |
getNumeric3CountryCodes()
Static method that returns all existing numeric-3 country codes. |
static boolean |
numeric3CountryCodeExists(int countryCode)
Verifies if a numeric-3 country code exists. |
static boolean |
numeric3CountryCodeExists(java.lang.String countryCode)
Verifies if a numeric-3 country code exists. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public CountryCodes()
| Method Detail |
public static boolean countryCodeExists(java.lang.String countryCode)
countryCode - The country code that needs to be checked
public static boolean alpha2CountryCodeExists(java.lang.String countryCode)
countryCode - The alpha-2 country code that needs to be checked
public static boolean alpha3CountryCodeExists(java.lang.String countryCode)
countryCode - The alpha-3 country code that needs to be checked
public static boolean numeric3CountryCodeExists(int countryCode)
countryCode - The country code that needs to be checked
public static boolean numeric3CountryCodeExists(java.lang.String countryCode)
countryCode - The country code that needs to be checked
public static Alpha2CountryCode getAlpha2CountryCode(java.lang.String countryCode)
countryCode - The country code used to create the Alpha2CountryCode object
java.lang.IllegalArgumentException - If the parameter country code is not well-formatted or does not existpublic static Alpha3CountryCode getAlpha3CountryCode(java.lang.String countryCode)
countryCode - The country code used to create the Alpha3CountryCode object
java.lang.IllegalArgumentException - If the parameter country code is not well-formatted or does not existpublic static Numeric3CountryCode getNumeric3CountryCode(int countryCode)
countryCode - The country code used to create the Numeric3CountryCode object
java.lang.IllegalArgumentException - If the parameter country code is not well-formatted or does not existpublic static Alpha2CountryCode[] getAlpha2CountryCodes()
public static Alpha3CountryCode[] getAlpha3CountryCodes()
public static Numeric3CountryCode[] getNumeric3CountryCodes()
public static CountryCodeRecord getCountryCodeRecord(java.lang.String countryCode)
public static CountryCodeRecord getCountryCodeRecord(Alpha2CountryCode alpha2CountryCode)
public static CountryCodeRecord getCountryCodeRecord(Alpha3CountryCode alpha3CountryCode)
public static CountryCodeRecord getCountryCodeRecord(Numeric3CountryCode numeric3CountryCode)
public static CountryCodeRecord[] getCountryCodeRecords()
|
Golibri | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||