public class TsMessageLoader extends Object implements MessageLoader
| Modifier and Type | Field and Description |
|---|---|
static String |
TS_FILE_EXTENSION |
| Constructor and Description |
|---|
TsMessageLoader() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canBeLoaded(String filePath)
Indicates whether file could be loaded by implementation.
|
static Map<String,String> |
dumpTsFile(Reader reader) |
static TypeScriptBabylonParserListener |
loadFile(String filePath) |
Map<String,String> |
loadPrimaryMessages(String filePath)
Loads primary language messages for given message file path.
|
Map<String,Map<String,String>> |
loadTranslations(String filePath,
List<String> languages)
Loads translations of messages for given message file path
filePath, searching for translations to
languages given in languages. |
static TypeScriptBabylonParserListener |
readTsFile(Reader reader) |
public static final String TS_FILE_EXTENSION
public boolean canBeLoaded(String filePath)
MessageLoadercanBeLoaded in interface MessageLoaderpublic Map<String,String> loadPrimaryMessages(String filePath)
MessageLoaderloadPrimaryMessages in interface MessageLoaderfilePath - path to message file to load messages fromfilePath, mapped by message keyspublic Map<String,Map<String,String>> loadTranslations(String filePath, List<String> languages)
MessageLoaderfilePath, searching for translations to
languages given in languages. For languages where the translation is missing, the translations are empty.loadTranslations in interface MessageLoaderfilePath - path to primary message file to load translated messages forlanguages - languages of translations to fetchpublic static Map<String,String> dumpTsFile(Reader reader) throws IOException
IOExceptionpublic static TypeScriptBabylonParserListener readTsFile(Reader reader) throws IOException
IOExceptionpublic static TypeScriptBabylonParserListener loadFile(String filePath)
Copyright © 2025 FG Forrest, a.s.. All rights reserved.