de.esprit.appsuite.type

## Enum Country

- java.lang.Object
- - java.lang.Enum<Country>
  - - de.esprit.appsuite.type.Country

- All Implemented Interfaces:
    NlsKey, PersistentName, Renderable, java.io.Serializable, java.lang.Comparable<Country>

      public enum Country
      extends java.lang.Enum<Country>
      implements Renderable, NlsKey, PersistentName

  This enum defines most common countries on earth. All of them have got a flag Icon for rendering.
  Author:
    Rainer Buesch

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `AD`
    `AE`
    `AF`
    `AL`
    `AR`
    `AS`
    `AT`
    `AU`
    `BA`
    `BE`
    `BG`
    `BH`
    `BM`
    `BR`
    `BY`
    `CA`
    `CH`
    `CL`
    `CN`
    `CO`
    `CR`
    `CX`
    `CY`
    `CZ`
    `DE`
    `DK`
    `DO`
    `DZ`
    `EE`
    `EG`
    `EN`
    `ES`
    `FI`
    `FO`
    `FR`
    `GB`
    `GE`
    `GI`
    `GR`
    `HK`
    `HM`
    `HR`
    `HU`
    `ID`
    `IE`
    `IL`
    `IN`
    `IS`
    `IT`
    `JM`
    `JO`
    `JP`
    `KR`
    `KW`
    `KZ`
    `LB`
    `LI`
    `LT`
    `LU`
    `LV`
    `MK`
    `MT`
    `MW`
    `MX`
    `MY`
    `NL`
    `NO`
    `NONE`
    `NZ`
    `PA`
    `PE`
    `PH`
    `PL`
    `PR`
    `PT`
    `RE`
    `RO`
    `RU`
    `SA`
    `SE`
    `SG`
    `SI`
    `SK`
    `SV`
    `TH`
    `TR`
    `TW`
    `UA`
    `US`
    `UY`
    `UZ`
    `VA`
    `VE`
    `VI`
    `VN`
    `YE`
    `ZA`

  - ### Field Summary

    - ### Fields inherited from interface de.esprit.appsuite.nls.NlsKey

      `SUB_KEY_ACTION, SUB_KEY_COLUMN, SUB_KEY_CONFIRM, SUB_KEY_CONST, SUB_KEY_DBO, SUB_KEY_DEMO, SUB_KEY_ERROR, SUB_KEY_FIELD, SUB_KEY_GUI, SUB_KEY_HELP, SUB_KEY_INFO, SUB_KEY_LABEL, SUB_KEY_MENU, SUB_KEY_MESSAGE, SUB_KEY_MISC, SUB_KEY_STATUS, SUB_KEY_TIP, SUB_KEY_TOOL, SUB_KEY_WINDOW, SUB_KEY_WORKFLOW`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static java.util.Locale` | `findBestLocaleForCountry(java.lang.String countryCode)` Finds the best matching Locale constant for the given language
    `static Country` | `fromPersistentName(java.lang.String countryCode)`
    `static java.util.Collection<Country>` | `getAllAvailableValues()` Returns all available Countries sorted by the translated name.
    `java.lang.String` | `getAppKey()` Returns the base prefix of the key
    `java.lang.String` | `getCountryCode()`
    `static java.util.Comparator` | `getCountryComparator()`
    `java.lang.String` | `getCountryName()`
    `static Country` | `getDefault()` Returns the `Country` constant that matches the default `Locale`
    `java.util.Locale` | `getLocale()`
    `java.lang.String` | `getPersistentName()` Returns the String value to be stored in the database or file.
    `java.awt.Color` | `getRenderColor()`
    `javax.swing.Icon` | `getRenderIcon()`
    `java.lang.String` | `getRenderText()`
    `static java.util.Collection<Country>` | `getSortedValues(java.util.EnumSet<Country> set)` Returns the Countries of the input set sorted by the translated name.
    `java.lang.String` | `getSubKey()` Returns the path of the key
    `java.lang.String` | `getText(java.lang.Object... args)` Returns the translated text, which is the value of the translation key as stored in the translation map.
    `java.lang.String` | `toString()` Returns the unique 2-char country code and the translated country name
    `static Country` | `valueOf(java.lang.String name)` Returns the enum constant of this type with the specified name.
    `static Country[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface de.esprit.appsuite.nls.NlsKey

      `name`

- - ### Enum Constant Detail

    - #### NONE

          public static final Country NONE

    - #### US

          public static final Country US

    - #### DE

          public static final Country DE

    - #### GB

          public static final Country GB

    - #### EN

          public static final Country EN

    - #### FR

          public static final Country FR

    - #### CA

          public static final Country CA

    - #### AU

          public static final Country AU

    - #### JP

          public static final Country JP

    - #### NL

          public static final Country NL

    - #### RU

          public static final Country RU

    - #### SE

          public static final Country SE

    - #### ES

          public static final Country ES

    - #### BE

          public static final Country BE

    - #### CN

          public static final Country CN

    - #### AT

          public static final Country AT

    - #### PL

          public static final Country PL

    - #### CH

          public static final Country CH

    - #### FI

          public static final Country FI

    - #### DK

          public static final Country DK

    - #### IT

          public static final Country IT

    - #### NO

          public static final Country NO

    - #### BR

          public static final Country BR

    - #### SG

          public static final Country SG

    - #### ZA

          public static final Country ZA

    - #### NZ

          public static final Country NZ

    - #### TH

          public static final Country TH

    - #### TW

          public static final Country TW

    - #### IE

          public static final Country IE

    - #### CZ

          public static final Country CZ

    - #### HU

          public static final Country HU

    - #### KR

          public static final Country KR

    - #### PT

          public static final Country PT

    - #### GR

          public static final Country GR

    - #### TR

          public static final Country TR

    - #### MY

          public static final Country MY

    - #### MX

          public static final Country MX

    - #### IL

          public static final Country IL

    - #### HR

          public static final Country HR

    - #### AF

          public static final Country AF

    - #### PR

          public static final Country PR

    - #### RO

          public static final Country RO

    - #### SI

          public static final Country SI

    - #### EE

          public static final Country EE

    - #### VE

          public static final Country VE

    - #### UA

          public static final Country UA

    - #### SK

          public static final Country SK

    - #### LU

          public static final Country LU

    - #### AR

          public static final Country AR

    - #### LV

          public static final Country LV

    - #### PH

          public static final Country PH

    - #### CO

          public static final Country CO

    - #### IS

          public static final Country IS

    - #### LT

          public static final Country LT

    - #### BA

          public static final Country BA

    - #### KZ

          public static final Country KZ

    - #### CL

          public static final Country CL

    - #### BG

          public static final Country BG

    - #### AE

          public static final Country AE

    - #### JM

          public static final Country JM

    - #### SA

          public static final Country SA

    - #### KW

          public static final Country KW

    - #### CY

          public static final Country CY

    - #### RE

          public static final Country RE

    - #### EG

          public static final Country EG

    - #### IN

          public static final Country IN

    - #### GI

          public static final Country GI

    - #### CR

          public static final Country CR

    - #### VA

          public static final Country VA

    - #### MT

          public static final Country MT

    - #### BY

          public static final Country BY

    - #### DO

          public static final Country DO

    - #### AS

          public static final Country AS

    - #### VI

          public static final Country VI

    - #### AL

          public static final Country AL

    - #### YE

          public static final Country YE

    - #### BH

          public static final Country BH

    - #### VN

          public static final Country VN

    - #### PE

          public static final Country PE

    - #### MK

          public static final Country MK

    - #### AD

          public static final Country AD

    - #### PA

          public static final Country PA

    - #### LI

          public static final Country LI

    - #### DZ

          public static final Country DZ

    - #### UY

          public static final Country UY

    - #### SV

          public static final Country SV

    - #### CX

          public static final Country CX

    - #### HM

          public static final Country HM

    - #### ID

          public static final Country ID

    - #### MW

          public static final Country MW

    - #### LB

          public static final Country LB

    - #### FO

          public static final Country FO

    - #### GE

          public static final Country GE

    - #### JO

          public static final Country JO

    - #### UZ

          public static final Country UZ

    - #### BM

          public static final Country BM

    - #### HK

          public static final Country HK

  - ### Method Detail

    - #### values

          public static Country[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (Country c : Country.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static Country valueOf(java.lang.String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `java.lang.IllegalArgumentException` - if this enum type has no constant with the specified name
        `java.lang.NullPointerException` - if the argument is null

    - #### getPersistentName

          public java.lang.String getPersistentName()

      Description copied from interface: `PersistentName`
      Returns the String value to be stored in the database or file. Note that the implementing Enum must also have a static method named fromPersistentName(String). This ensures that the Enum can be instantiated from the String read from database or file.
      Specified by:
        `getPersistentName` in interface `PersistentName`

    - #### getCountryCode

          public java.lang.String getCountryCode()

    - #### getCountryName

          public java.lang.String getCountryName()

    - #### getRenderColor

          public java.awt.Color getRenderColor()

      Specified by:
        `getRenderColor` in interface `Renderable`

    - #### getRenderIcon

          public javax.swing.Icon getRenderIcon()

      Specified by:
        `getRenderIcon` in interface `Renderable`

    - #### getRenderText

          public java.lang.String getRenderText()

      Specified by:
        `getRenderText` in interface `Renderable`

    - #### getAppKey

          public java.lang.String getAppKey()

      Description copied from interface: `NlsKey`
      Returns the base prefix of the key
      Specified by:
        `getAppKey` in interface `NlsKey`

    - #### getSubKey

          public java.lang.String getSubKey()

      Description copied from interface: `NlsKey`
      Returns the path of the key
      Specified by:
        `getSubKey` in interface `NlsKey`

    - #### getText

          public java.lang.String getText(java.lang.Object... args)

      Description copied from interface: `NlsKey`
      Returns the translated text, which is the value of the translation key as stored in the translation map.
      Specified by:
        `getText` in interface `NlsKey`

    - #### getAllAvailableValues

          public static java.util.Collection<Country> getAllAvailableValues()

      Returns all available Countries sorted by the translated name. Does NOT contain the NONE value.

    - #### getSortedValues

          public static java.util.Collection<Country> getSortedValues(java.util.EnumSet<Country> set)

      Returns the Countries of the input set sorted by the translated name.

    - #### getLocale

          public java.util.Locale getLocale()

    - #### findBestLocaleForCountry

          public static java.util.Locale findBestLocaleForCountry(java.lang.String countryCode)

      Finds the best matching Locale constant for the given language

    - #### fromPersistentName

          public static Country fromPersistentName(java.lang.String countryCode)

    - #### getDefault

          public static Country getDefault()

      Returns the `Country` constant that matches the default `Locale`

    - #### getCountryComparator

          public static java.util.Comparator getCountryComparator()

    - #### toString

          public java.lang.String toString()

      Returns the unique 2-char country code and the translated country name
      Overrides:
        `toString` in class `java.lang.Enum<Country>`

Copyright © 2014 EsprIT-Systems. All Rights Reserved.