Oracle

com.compoze.util
Class CountryRegionEnumerator.Country

java.lang.Object
  extended by com.compoze.util.CountryRegionEnumerator.Country
All Implemented Interfaces:
java.lang.Comparable
Enclosing class:
CountryRegionEnumerator

public class CountryRegionEnumerator.Country
extends java.lang.Object
implements java.lang.Comparable

This class represents a country.


Constructor Summary
CountryRegionEnumerator.Country(java.lang.String sFullName, java.lang.String sAbbreviatedName)
          Constructor.
 
Method Summary
 void addRegion(CountryRegionEnumerator.Region region)
          Add a region to the country.
 int compareTo(java.lang.Object o1)
          Compare this country to the given one.
 java.lang.String getAbbreviatedName()
          Get the abbreviated name of the country.
 java.lang.String getFullName()
          Get the full name of the country.
 java.util.TreeMap getRegions()
          Get all of the regions for a country.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CountryRegionEnumerator.Country

public CountryRegionEnumerator.Country(java.lang.String sFullName,
                                       java.lang.String sAbbreviatedName)
Constructor.

Parameters:
sFullName - the full name of the country
sAbbreviatedName - the abbreviated name of the country
Method Detail

addRegion

public void addRegion(CountryRegionEnumerator.Region region)
Add a region to the country.

Parameters:
region - the region to add

getRegions

public java.util.TreeMap getRegions()
Get all of the regions for a country.

Parameters:
sCountry -
Returns:
the collection of regions (Country objects)

getFullName

public java.lang.String getFullName()
Get the full name of the country.

Returns:
the full name of the country

getAbbreviatedName

public java.lang.String getAbbreviatedName()
Get the abbreviated name of the country.

Returns:
the abbreviated name of the country

compareTo

public int compareTo(java.lang.Object o1)
Compare this country to the given one.

Specified by:
compareTo in interface java.lang.Comparable
Parameters:
o1 - object to compare to (must be a Country)
Returns:
less than 0, 0 or greater than zero
See Also:
Comparable

Oracle

Copyright ©1999-2008 Oracle All rights reserved.