fi.karppinen.xml
Class LangUtil
java.lang.Object
fi.karppinen.xml.LangUtil
public class LangUtil
- extends Object
Converts between Locale and XML-compatible language codes.
- Version:
- $Id: LangUtil.java,v 1.1 2006/10/30 19:57:09 hsivonen Exp $
- Author:
- hsivonen
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LangUtil
public LangUtil()
codeToLocale
public static Locale codeToLocale(String code)
- Converts between XML-compatible language codes and
Locale.
- Parameters:
code - the language code
- Returns:
- the corresponding locale
localeToCode
public static String localeToCode(Locale loc)
- Converts between
Locale and XML-compatible language codes.
- Parameters:
loc - the locale
- Returns:
- the language code