public class HttpTranslateRpc extends Object implements TranslateRpc
TranslateRpc.Option
Constructor and Description |
---|
HttpTranslateRpc(TranslateOptions options) |
Modifier and Type | Method and Description |
---|---|
List<List<com.google.api.services.translate.model.DetectionsResourceItems>> |
detect(List<String> texts)
Detects the language of the provided texts.
|
List<com.google.api.services.translate.model.LanguagesResource> |
listSupportedLanguages(Map<TranslateRpc.Option,?> optionMap)
Returns a list of the languages supported by Google Translation.
|
List<com.google.api.services.translate.model.TranslationsResource> |
translate(List<String> texts,
Map<TranslateRpc.Option,?> optionMap)
Translates the provided texts.
|
public HttpTranslateRpc(TranslateOptions options)
public List<List<com.google.api.services.translate.model.DetectionsResourceItems>> detect(List<String> texts)
TranslateRpc
detect
in interface TranslateRpc
texts
- the texts to translatepublic List<com.google.api.services.translate.model.LanguagesResource> listSupportedLanguages(Map<TranslateRpc.Option,?> optionMap)
TranslateRpc
listSupportedLanguages
in interface TranslateRpc
optionMap
- options to listing language translationspublic List<com.google.api.services.translate.model.TranslationsResource> translate(List<String> texts, Map<TranslateRpc.Option,?> optionMap)
TranslateRpc
translate
in interface TranslateRpc
texts
- the texts to translateoptionMap
- options to text translationCopyright © 2019 Google LLC. All rights reserved.