Class I18n

java.lang.Object
org.apache.xml.security.utils.I18n

public class I18n extends Object
The Internationalization (I18N) pack.
Author:
Christian Geuer-Pollmann
  • Field Details

    • NOT_INITIALIZED_MSG

      public static final String NOT_INITIALIZED_MSG
      Field NOT_INITIALIZED_MSG
      See Also:
    • defaultLanguageCode

      public static String defaultLanguageCode
      Field defaultLanguageCode
    • defaultCountryCode

      public static String defaultCountryCode
      Field defaultCountryCode
    • resourceBundle

      protected static ResourceBundle resourceBundle
      Field resourceBundle
    • alreadyInitialized

      protected static boolean alreadyInitialized
      Field alreadyInitialized
    • _languageCode

      protected static String _languageCode
      Field _languageCode
    • _countryCode

      protected static String _countryCode
      Field _countryCode
  • Method Details

    • translate

      public static String translate(String message, Object[] args)
      Method translate translates a message ID into an internationalized String, see alse XMLSecurityException.getExceptionMEssage(). The strings are stored in the ResourceBundle, which is identified in exceptionMessagesResourceBundleBase
      Parameters:
      message -
      args - is an Object[] array of strings which are inserted into the String which is retrieved from the ResouceBundle
      Returns:
      message translated
    • translate

      public static String translate(String message)
      Method translate translates a message ID into an internationalized String, see alse XMLSecurityException.getExceptionMEssage()
      Parameters:
      message -
      Returns:
      message translated
    • getExceptionMessage

      public static String getExceptionMessage(String msgID)
      Method getExceptionMessage
      Parameters:
      msgID -
      Returns:
      message translated
    • getExceptionMessage

      public static String getExceptionMessage(String msgID, Exception originalException)
      Method getExceptionMessage
      Parameters:
      msgID -
      originalException -
      Returns:
      message translated
    • getExceptionMessage

      public static String getExceptionMessage(String msgID, Object[] exArgs)
      Method getExceptionMessage
      Parameters:
      msgID -
      exArgs -
      Returns:
      message translated
    • init

      public static void init(String _defaultLanguageCode, String _defaultCountryCode)
      Method init
      Parameters:
      _defaultLanguageCode -
      _defaultCountryCode -
    • initLocale

      public static void initLocale(String languageCode, String countryCode)
      Method initLocale
      Parameters:
      languageCode -
      countryCode -