org.xbrlapi.impl
Class LanguageMap
java.lang.Object
org.xbrlapi.impl.LanguageMap
public class LanguageMap
- extends Object
Enables easy management of collections of language definitions.
- Author:
- Geoff Shuetrim (geoff@galexy.net)
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LanguageMap
public LanguageMap()
addLanguage
public void addLanguage(Language language)
throws XBRLException
- Adds a language to the map.
- Parameters:
language - The language to add.
- Throws:
XBRLException
addAll
public void addAll(List<Language> languages)
throws XBRLException
- Adds a list of languages to the map.
- Parameters:
languages - The languages to add.
- Throws:
XBRLException
getCodes
public Set<String> getCodes()
- Returns:
- the set of all codes of languages in the map.
contains
public boolean contains(String code,
String encoding)
- Parameters:
code - The code to test for.encoding - The encoding to test for.
- Returns:
- true if a language is in the map that
gives the name for the code language in the encoding language.
get
public Language get(String code,
String encoding)
- Parameters:
code - the code of the language.encoding - the encoding of the langauge.
- Returns:
- the language or null if none is available.