Package net.ygbstudio.jbrave.api.options
Enum Class SearchLanguage
- All Implemented Interfaces:
Serializable,Comparable<SearchLanguage>,Constable,BraveAPIConstant,LanguageIdentifier,ProvidedOption,SearchOption
Enum representing the different language identifiers supported by the Brave Search API.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionArabic.Basque.Bengali.Bulgarian.Catalan.Chinese (Simplified).Chinese (Traditional).Croatian.Czech.Danish.Dutch.English.English (United Kingdom).Estonian.Finnish.French.Galician.German.Greek.Gujarati.Hebrew.Hindi.Hungarian.Icelandic.Italian.Japanese.Kannada.Korean.Latvian.Lithuanian.Malay.Malayalam.Marathi.Norwegian (Bokmål).Polish.Portuguese (Brazil).Portuguese (Portugal).Punjabi.Romanian.Russian.Serbian (Cyrillic).Slovak.Slovenian.Spanish.Swedish.Tamil.Telugu.Thai.Turkish.Ukrainian.Vietnamese. -
Field Summary
Fields inherited from interface net.ygbstudio.jbrave.core.domain.BraveAPIConstant
SEARCH_API_BASEFields inherited from interface net.ygbstudio.jbrave.core.domain.provided.LanguageIdentifier
URL_PARAMFields inherited from interface net.ygbstudio.jbrave.core.domain.ProvidedOption
UNITS -
Method Summary
Modifier and TypeMethodDescription@NotNull @Unmodifiable SearchOptionCarrier<String> Converts this language identifier to aSearchOptionCarrierfor use in a search request.@NotNull StringurlParam()Returns the URL parameter associated with this constant.value()Returns the value of the constant.static SearchLanguageReturns the enum constant of this class with the specified name.static SearchLanguage[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ARABIC
Arabic. -
BASQUE
Basque. -
BENGALI
Bengali. -
BULGARIAN
Bulgarian. -
CATALAN
Catalan. -
CHINESE_SIMPLIFIED
Chinese (Simplified). -
CHINESE_TRADITIONAL
Chinese (Traditional). -
CROATIAN
Croatian. -
CZECH
Czech. -
DANISH
Danish. -
DUTCH
Dutch. -
ENGLISH
English. -
ENGLISH_UNITED_KINGDOM
English (United Kingdom). -
ESTONIAN
Estonian. -
FINNISH
Finnish. -
FRENCH
French. -
GALICIAN
Galician. -
GERMAN
German. -
GREEK
Greek. -
GUJARATI
Gujarati. -
HEBREW
Hebrew. -
HINDI
Hindi. -
HUNGARIAN
Hungarian. -
ICELANDIC
Icelandic. -
ITALIAN
Italian. -
JAPANESE
Japanese. -
KANNADA
Kannada. -
KOREAN
Korean. -
LATVIAN
Latvian. -
LITHUANIAN
Lithuanian. -
MALAY
Malay. -
MALAYALAM
Malayalam. -
MARATHI
Marathi. -
NORWEGIAN_BOKMAL
Norwegian (Bokmål). -
POLISH
Polish. -
PORTUGUESE_BRAZIL
Portuguese (Brazil). -
PORTUGUESE_PORTUGAL
Portuguese (Portugal). -
PUNJABI
Punjabi. -
ROMANIAN
Romanian. -
RUSSIAN
Russian. -
SERBIAN_CYRILIC
Serbian (Cyrillic). -
SLOVAK
Slovak. -
SLOVENIAN
Slovenian. -
SPANISH
Spanish. -
SWEDISH
Swedish. -
TAMIL
Tamil. -
TELUGU
Telugu. -
THAI
Thai. -
TURKISH
Turkish. -
UKRAINIAN
Ukrainian. -
VIETNAMESE
Vietnamese.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
value
Description copied from interface:BraveAPIConstantReturns the value of the constant. Must be implemented by the enum constants.- Specified by:
valuein interfaceBraveAPIConstant- Returns:
- the value of the constant
-
urlParam
Description copied from interface:BraveAPIConstantReturns the URL parameter associated with this constant. It can be implemented by default at the interface level with the value of the parameter.This method is used to generate the URL parameter for the API requests and represents a unit of
option/parameterName/parameterConstant + "=" + parameterValue.A
parameterValuemay be provided by the API or require that the client provides it. By default, all options/parameters names are provided by the API.- Specified by:
urlParamin interfaceBraveAPIConstant- Returns:
- the URL parameter associated with this constant
- See Also:
-
toSearchOption
@Contract(" -> new") @NotNull public @NotNull @Unmodifiable SearchOptionCarrier<String> toSearchOption()Description copied from interface:LanguageIdentifierConverts this language identifier to aSearchOptionCarrierfor use in a search request.- Specified by:
toSearchOptionin interfaceLanguageIdentifier- Specified by:
toSearchOptionin interfaceProvidedOption- Returns:
- the
SearchOptionCarrierrepresenting this language
-