public abstract class AbstractISOCodeMapper
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private boolean |
m_bUseDefaultLocale |
private java.lang.String |
m_iso2 |
private java.util.Locale |
m_locale |
private int |
MAX_LENGTH |
Constructor and Description |
---|
AbstractISOCodeMapper()
Constructs an empty mapper object.
|
AbstractISOCodeMapper(int a_maxTextLength)
Constructs an empty mapper object.
|
AbstractISOCodeMapper(java.lang.String a_ISOCode)
Constructs a new mapper object that uses the default Locale to translate its ISO code.
|
AbstractISOCodeMapper(java.lang.String a_ISOCode,
int a_maxTextLength)
Constructs a new mapper that uses the default Locale to translate its ISO code.
|
AbstractISOCodeMapper(java.lang.String a_ISOCode,
int a_maxTextLength,
java.util.Locale a_locale)
Constructs a new mapper object that uses a specific Locale to translate its ISO code.
|
AbstractISOCodeMapper(java.lang.String a_ISOCode,
java.util.Locale a_locale)
Constructs a new mapper object that uses a specific Locale to translate its ISO code.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object a_object)
Returns if the ISO codes of two mapper objects are equal.
|
protected abstract java.lang.String |
getChooseMessage()
Returns a message that is displayed when this mapped object has an empty ISO code.
|
java.lang.String |
getISOCode()
Returns the ISO country code stored in this CountryMapper object.
|
protected abstract java.lang.String |
getJRETransaltionOfISOCode(java.lang.String a_ISOCode,
java.util.Locale a_locale) |
int |
hashCode()
Returns the hash code of the ISO country code.
|
java.lang.String |
toString()
Returns the localised name of the ISO country code of this
CountryMapper object.
|
private final int MAX_LENGTH
private boolean m_bUseDefaultLocale
private java.lang.String m_iso2
private java.util.Locale m_locale
public AbstractISOCodeMapper()
public AbstractISOCodeMapper(int a_maxTextLength)
a_maxTextLength
- the maximum length of the toString() outputpublic AbstractISOCodeMapper(java.lang.String a_ISOCode, int a_maxTextLength) throws java.lang.IllegalArgumentException
a_ISOCode
- a two-letter ISO codea_maxTextLength
- the maximum length of the toString() outputjava.lang.IllegalArgumentException
- if the ISO code does not have two characterspublic AbstractISOCodeMapper(java.lang.String a_ISOCode) throws java.lang.IllegalArgumentException
a_ISOCode
- a two-letter ISO codejava.lang.IllegalArgumentException
- if the ISO code does not have two characterspublic AbstractISOCodeMapper(java.lang.String a_ISOCode, java.util.Locale a_locale) throws java.lang.IllegalArgumentException
a_ISOCode
- a two-letter ISO codea_locale
- a Localejava.lang.IllegalArgumentException
- if the ISO code does not have two characterspublic AbstractISOCodeMapper(java.lang.String a_ISOCode, int a_maxTextLength, java.util.Locale a_locale) throws java.lang.IllegalArgumentException
a_ISOCode
- a two-letter ISO codea_locale
- a Localea_maxTextLength
- the maximum length of the toString() outputjava.lang.IllegalArgumentException
- if the ISO code does not have two characterspublic final java.lang.String getISOCode()
public final boolean equals(java.lang.Object a_object)
equals
in class java.lang.Object
a_object
- an Objectpublic final int hashCode()
hashCode
in class java.lang.Object
protected abstract java.lang.String getChooseMessage()
protected abstract java.lang.String getJRETransaltionOfISOCode(java.lang.String a_ISOCode, java.util.Locale a_locale)
public final java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2023. All rights reserved.