Class LocalizationServiceProxy
-
- All Implemented Interfaces:
-
org.somda.sdc.glue.consumer.localization.LocalizationServiceAccess
public class LocalizationServiceProxy implements LocalizationServiceAccess
Controller class that is responsible for invoking localization requests.
-
-
Method Summary
Modifier and Type Method Description ListenableFuture<GetLocalizedTextResponse>getLocalizedText(GetLocalizedText getLocalizedText)Invokes a localization service to get localized texts. ListenableFuture<GetSupportedLanguagesResponse>getSupportedLanguages(GetSupportedLanguages getSupportedLanguages)Invokes a localization service to get supported languages. voidcachePrefetch(BigInteger version)Calls a synchronous cache prefetch of localized texts by provided version. voidcachePrefetch(BigInteger version, List<String> lang)Calls a synchronous cache prefetch of localized texts by provided version and languages. -
-
Method Detail
-
getLocalizedText
ListenableFuture<GetLocalizedTextResponse> getLocalizedText(GetLocalizedText getLocalizedText)
Invokes a localization service to get localized texts.
If there is no localization service available, this function returns with a cancelled future.
- Returns:
a future object that contains a list of localized texts.
-
getSupportedLanguages
ListenableFuture<GetSupportedLanguagesResponse> getSupportedLanguages(GetSupportedLanguages getSupportedLanguages)
Invokes a localization service to get supported languages.
If there is no localization service available, this function returns with a cancelled future.
- Returns:
a future object that contains a list of supported languages.
-
cachePrefetch
void cachePrefetch(BigInteger version)
Calls a synchronous cache prefetch of localized texts by provided version.
- Parameters:
version- - a version of localized texts to be included into cache.
-
cachePrefetch
void cachePrefetch(BigInteger version, List<String> lang)
Calls a synchronous cache prefetch of localized texts by provided version and languages.
- Parameters:
version- a version of localized texts to be included into cache.lang- optional list of languages to be included into cache.
-
-
-
-