Class LanguageApiImpl
- java.lang.Object
-
- com.github.vbauer.yta.service.basic.AbstractApi
-
- com.github.vbauer.yta.service.fraction.impl.LanguageApiImpl
-
- All Implemented Interfaces:
LanguageApi
@ThreadSafe public class LanguageApiImpl extends AbstractApi implements LanguageApi
SeeLanguageApi
.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ATTR_UI
static java.lang.String
METHOD_GET_LANGS
-
Constructor Summary
Constructors Constructor Description LanguageApiImpl(ApiContext context)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Languages
all()
Gets a list of translation directions and available languages supported by the service.Languages
all(Language ui)
Gets a list of translation directions and available languages supported by the service.Languages
all(java.lang.String ui)
Gets a list of translation directions and available languages supported by the service.-
Methods inherited from class com.github.vbauer.yta.service.basic.AbstractApi
callMethod, client, converter
-
-
-
-
Field Detail
-
METHOD_GET_LANGS
public static final java.lang.String METHOD_GET_LANGS
- See Also:
- Constant Field Values
-
ATTR_UI
public static final java.lang.String ATTR_UI
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
LanguageApiImpl
public LanguageApiImpl(ApiContext context)
-
-
Method Detail
-
all
@Nonnull public Languages all()
Gets a list of translation directions and available languages supported by the service. In this case, language names (Language.name()
) are not fetched from the Yandex.Translate service.- Specified by:
all
in interfaceLanguageApi
- Returns:
- information about available languages and directions of translation
-
all
@Nonnull public Languages all(@Nullable Language ui)
Gets a list of translation directions and available languages supported by the service.- Specified by:
all
in interfaceLanguageApi
- Parameters:
ui
- if set, the response contains explanations of language codes- Returns:
- information about available languages and directions of translation
-
all
@Nonnull public Languages all(@Nullable java.lang.String ui)
Gets a list of translation directions and available languages supported by the service.- Specified by:
all
in interfaceLanguageApi
- Parameters:
ui
- if set, the response contains explanations of language codes- Returns:
- information about available languages and directions of translation
-
-