Interface CountrySubdivision
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
CountrySubdivisionImpl
Represents a principal subdivision of a Country (e.g. province or state).
This entity should be used only for lookup and filtering purposes only. For example, to help populate a drop-down to those States/Provinces/Regions you only wish to ship to.
{@link http://www.iso.org/iso/country_codes.htm} {@link http://en.wikipedia.org/wiki/ISO_3166-2}
- Author:
- Elbert Bautista (elbertbautista)
-
Method Summary
Modifier and TypeMethodDescriptionThe primary key - Ideally, implementations should use the ISO 3166-2 code of the country subdivision.More friendly abbreviation that can be used for display purposes e.g.A category that represents the subdivision of this Country.The country where this subdivision resides e.g.getName()Full name for display purposes e.g.voidsetAbbreviation(String abbreviation) Sets the primary key abbreviationvoidsetAlternateAbbreviation(String alternateAbbreviation) sets the alternate abbreviationvoidsetCategory(CountrySubdivisionCategory category) sets the country subdivision categoryvoidsetCountry(Country country) sets the country in which this subdivision residesvoidsets the name
-
Method Details
-
getAbbreviation
String getAbbreviation()The primary key - Ideally, implementations should use the ISO 3166-2 code of the country subdivision. e.g. "US-TX" or "GB-WSM" {@link http://en.wikipedia.org/wiki/ISO_3166-2} -
setAbbreviation
Sets the primary key abbreviation- Parameters:
abbreviation- - e.g. "US-TX" or "GB-WSM"
-
getAlternateAbbreviation
String getAlternateAbbreviation()More friendly abbreviation that can be used for display purposes e.g. "TX", "CA", "NY"- Returns:
- - the alternate abbreviation
-
setAlternateAbbreviation
sets the alternate abbreviation- Parameters:
alternateAbbreviation- - e.g. "TX", "CA", "NY"
-
getName
String getName()Full name for display purposes e.g. "Texas", "California", "New York"- Returns:
- - the alternate abbreviation
-
setName
sets the name- Parameters:
name- - e.g. "Texas", "California", "New York"
-
getCategory
CountrySubdivisionCategory getCategory()A category that represents the subdivision of this Country. e.g. "State", "Province", "District"- Returns:
- - the country subdivision category
-
setCategory
sets the country subdivision category- Parameters:
category- - e.g. "State", "Province", "District"
-
getCountry
Country getCountry()The country where this subdivision resides e.g. "US", "GB"- Returns:
- - the country where this subdivision resides
-
setCountry
sets the country in which this subdivision resides- Parameters:
country- - e.g. "US", "GB"
-