campus.compass
Class CountryCode

java.lang.Object
  |
  +--campus.compass.CountryCode

public class CountryCode
extends java.lang.Object

Manages the mapping of the country name to its 2-char code.

Version:
$Id: CountryCode.java,v 1.1 2003/09/08 05:22:44 glchen Exp $
Author:
Guanling Chen

Field Summary
private static java.util.Hashtable _country
           
 
Constructor Summary
private CountryCode()
           
 
Method Summary
static java.lang.String getCountryCode(java.lang.String name)
          Get 2-digit code of a country for specified name.
static java.lang.String getCountryName(java.lang.String code)
          Get full name of a country for specified code.
private static void initCountryMapping()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_country

private static java.util.Hashtable _country
Constructor Detail

CountryCode

private CountryCode()
Method Detail

getCountryCode

public static java.lang.String getCountryCode(java.lang.String name)
Get 2-digit code of a country for specified name.


getCountryName

public static java.lang.String getCountryName(java.lang.String code)
Get full name of a country for specified code.


initCountryMapping

private static void initCountryMapping()