Class Country


public final class Country extends GO_CharacterString
JAXB wrapper for Locale in order to wrap the value in an XML element as specified by ISO 19115-3 standard. See package documentation for more information about the handling of CodeList in ISO 19115-3.

This adapter formats the locale like below:

Note that <gco:CharacterString> can be substituted to the country code.
Since:
0.3
Version:
1.0
Author:
Cédric Briançon (Geomatys), Martin Desruisseaux (Geomatys), Cullen Rombach (Image Matters)
  • Method Details

    • create

      public static Country create(Context context, Locale locale)
      Creates a new wrapper for the given locale.
      Parameters:
      context - the current (un)marshalling context, or null if none.
      locale - the value to marshal, or null.
      Returns:
      the country to marshal, or null if the given locale was null or if its Locale.getCountry() attribute is the empty string.
    • getLocale

      public static Locale getLocale(Context context, LanguageCode language, Country country, Class<?> caller)
      Returns the locale for the given language and country (which may be null), or null if none.
      Parameters:
      context - the current (un)marshalling context, or null if none.
      language - the wrapper for the language value.
      country - the wrapper for the country value.
      caller - the class which is invoking this method, used only in case of warning.
      Returns:
      a locale which represents the language and country value.