|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectch.elca.el4j.util.codelist.CodelistUtility
public class CodelistUtility
This class implements the base functionality for enums which represent codelists and implement the Interface Codelist. Since the extensibility of enum types is not supported by the language construct, the functional implementation is provided in this utility class.
Constructor Summary | |
---|---|
CodelistUtility(String resourceBaseName)
Constructor. |
Method Summary | |
---|---|
static List<Locale> |
getAvailableLocales(String resourceBaseName)
Returns a list of all java locales for which a .properties file corresponding to the ResourceBundle base name is available. |
List<Locale> |
getLocales()
Returns a list of all java locales for which a translation of the textual description is available. |
String |
loadLongText(String code,
Locale lang)
Getter for the long textual description of the code in a given language. |
String |
loadShortText(String code,
Locale lang)
Getter for the short textual description of the code in a given language. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CodelistUtility(String resourceBaseName)
resourceBaseName
- Base name of the associated ResourceBundleMethod Detail |
---|
public String loadShortText(String code, Locale lang)
code
- Code for which the text is loadedlang
- Java Locale of the desired language for the returned text
public String loadLongText(String code, Locale lang)
code
- Code for which the text is loadedlang
- Java Locale of the desired language for the returned text
public List<Locale> getLocales()
public static List<Locale> getAvailableLocales(String resourceBaseName)
resourceBaseName
- Base name of the ResourceBundle
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |