|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbr.uerj.language.LanguageTool
public class LanguageTool
Classe Auxiliar para suporte multilingue.
| Field Summary | |
|---|---|
private static java.util.Properties |
langProperties
Objeto Properties com o mapeamento Chave e Conteúdo |
private static java.util.HashMap |
map
Map que faz o mapeamento Chave e Conteúdo default Usada quando o properties não puder ser carregado ou alguma chave não for encontrada no properties |
private static java.lang.String |
propLanguageFileName
Nome do arquivo Properties com o mapeamento Chave e Conteúdo |
| Constructor Summary | |
|---|---|
LanguageTool()
|
|
| Method Summary | |
|---|---|
static void |
addString(java.lang.String strKey,
java.lang.String strContent)
Adiciona o par Chave e Conteúdo a Map. |
static void |
changeLanguage(java.lang.String strFile)
Seta o idioma a ser usado passando o nome do arquivo properties a ser consultado. |
static java.lang.String |
getString(java.lang.String strKey)
Retorna String para chave fornecida, buscando no arquivo de properties do idioma selecionado. |
static void |
loadPropertiesLanguage()
Carrega o arquivo properties com o idioma escolhido |
static void |
setLanguageDefault(java.lang.String strFile)
Seta o idioma default a ser usado logo no início do programa. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static java.lang.String propLanguageFileName
private static java.util.Properties langProperties
private static java.util.HashMap map
| Constructor Detail |
|---|
public LanguageTool()
| Method Detail |
|---|
public static void setLanguageDefault(java.lang.String strFile)
strFile - Nome do arquivo Propertiespublic static void changeLanguage(java.lang.String strFile)
strFile - Nome do arquivo Propertiespublic static void loadPropertiesLanguage()
public static void addString(java.lang.String strKey,
java.lang.String strContent)
strKey - ChavestrContent - Conteúdopublic static java.lang.String getString(java.lang.String strKey)
strKey - Chave a ser buscada no arquivo de properties
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||