Package com.e1c.langtool.storage.regex
Class RegExDictionaryData
java.lang.Object
com.e1c.langtool.storage.regex.RegExDictionaryData
- All Implemented Interfaces:
DictionaryData
-
Constructor Summary
ConstructorsConstructorDescriptionRegExDictionaryData(String languageCode, org.eclipse.core.resources.IProject project, ITranslatingProjectManager translatingProjectManager, ITranslationStorageManager storageManager) -
Method Summary
Modifier and TypeMethodDescriptionGets the comment.getComment(TranslationKey translationKey) Gets the comment for the translation key.getTranslation(TranslationKey translationKey) Gets the translation by the translation key.booleanhasKeyForValue(String value, TranslationKey skipKey) Checks if there is a key for the translation value.removeTranslation(TranslationKey translationKey) Removes the translation by the key.voidsetComment(String comment) Sets top data object comment.voidsetSettings(RegExSettings settings) setTranslation(TranslationKey translationKey, String value, String comment) Sets the translation and comment for the translation key.
-
Constructor Details
-
RegExDictionaryData
public RegExDictionaryData(String languageCode, org.eclipse.core.resources.IProject project, ITranslatingProjectManager translatingProjectManager, ITranslationStorageManager storageManager)
-
-
Method Details
-
getSettings
-
setSettings
-
setComment
Description copied from interface:DictionaryDataSets top data object comment.- Specified by:
setCommentin interfaceDictionaryData- Parameters:
comment- the new comment, can benull.
-
getComment
Description copied from interface:DictionaryDataGets the comment.- Specified by:
getCommentin interfaceDictionaryData- Returns:
- the comment, can return
null.
-
removeTranslation
Description copied from interface:DictionaryDataRemoves the translation by the key.- Specified by:
removeTranslationin interfaceDictionaryData- Parameters:
translationKey- the translation key, cannot benull.- Returns:
- the translation, can return
nullif was no any translation.
-
getComment
Description copied from interface:DictionaryDataGets the comment for the translation key.- Specified by:
getCommentin interfaceDictionaryData- Parameters:
translationKey- the translation key, cannot benull.- Returns:
- the comment, can return
null.
-
getTranslation
Description copied from interface:DictionaryDataGets the translation by the translation key.- Specified by:
getTranslationin interfaceDictionaryData- Parameters:
translationKey- the translation key, cannot benull.- Returns:
- the translation, can return
null.
-
setTranslation
Description copied from interface:DictionaryDataSets the translation and comment for the translation key.- Specified by:
setTranslationin interfaceDictionaryData- Parameters:
translationKey- the translation key, cannot benull.value- the value, can benull.comment- the comment, can benull.- Returns:
- the previous translation, can return
nullif was no translation before.
-
hasKeyForValue
Description copied from interface:DictionaryDataChecks if there is a key for the translation value.- Specified by:
hasKeyForValuein interfaceDictionaryData- Parameters:
value- the translation value, cannot benull.skipKey- the key which should be ignored if translation value found for this key, may benullif need to check all keys.- Returns:
- true, if data object has translation value
-