Enum Class MarketLocale

java.lang.Object
java.lang.Enum<MarketLocale>
net.ygbstudio.jbrave.api.options.MarketLocale
All Implemented Interfaces:
Serializable, Comparable<MarketLocale>, Constable, BraveAPIConstant, RegionLocaleIdentifier, ProvidedOption, SearchOption

public enum MarketLocale extends Enum<MarketLocale> implements RegionLocaleIdentifier
Enumeration representing a market locale supported by the Brave Search API.

This enumeration implements the RegionLocaleIdentifier interface, providing methods for URL parameter generation.

See Also:
  • Enum Constant Details

    • ARGENTINA

      public static final MarketLocale ARGENTINA
      Argentina.
    • AUSTRALIA

      public static final MarketLocale AUSTRALIA
      Australia.
    • AUSTRIA

      public static final MarketLocale AUSTRIA
      Austria.
    • BELGIUM_DUTCH

      public static final MarketLocale BELGIUM_DUTCH
      Belgium (Dutch).
    • BELGIUM_FRENCH

      public static final MarketLocale BELGIUM_FRENCH
      Belgium (French).
    • BRAZIL

      public static final MarketLocale BRAZIL
      Brazil.
    • CANADA_ENGLISH

      public static final MarketLocale CANADA_ENGLISH
      Canada (English).
    • CANADA_FRENCH

      public static final MarketLocale CANADA_FRENCH
      Canada (French).
    • CHILE

      public static final MarketLocale CHILE
      Chile.
    • DENMARK

      public static final MarketLocale DENMARK
      Denmark.
    • FINLAND

      public static final MarketLocale FINLAND
      Finland.
    • FRANCE

      public static final MarketLocale FRANCE
      France.
    • GERMANY

      public static final MarketLocale GERMANY
      Germany.
    • GREECE

      public static final MarketLocale GREECE
      Greece.
    • HONG_KONG

      public static final MarketLocale HONG_KONG
      Hong Kong.
    • INDIA

      public static final MarketLocale INDIA
      India.
    • INDONESIA

      public static final MarketLocale INDONESIA
      Indonesia.
    • ITALY

      public static final MarketLocale ITALY
      Italy.
    • JAPAN

      public static final MarketLocale JAPAN
      Japan.
    • KOREA

      public static final MarketLocale KOREA
      Korea.
    • MALAYSIA

      public static final MarketLocale MALAYSIA
      Malaysia.
    • MEXICO

      public static final MarketLocale MEXICO
      Mexico.
    • NETHERLANDS

      public static final MarketLocale NETHERLANDS
      Netherlands.
    • NEW_ZEALAND

      public static final MarketLocale NEW_ZEALAND
      New Zealand.
    • NORWAY

      public static final MarketLocale NORWAY
      Norway.
    • CHINA

      public static final MarketLocale CHINA
      China.
    • POLAND

      public static final MarketLocale POLAND
      Poland.
    • PHILIPPINES

      public static final MarketLocale PHILIPPINES
      Philippines.
    • RUSSIA

      public static final MarketLocale RUSSIA
      Russia.
    • SOUTH_AFRICA

      public static final MarketLocale SOUTH_AFRICA
      South Africa.
    • SPAIN

      public static final MarketLocale SPAIN
      Spain.
    • SWEDEN

      public static final MarketLocale SWEDEN
      Sweden.
    • SWITZERLAND_FRENCH

      public static final MarketLocale SWITZERLAND_FRENCH
      Switzerland (French).
    • SWITZERLAND_GERMAN

      public static final MarketLocale SWITZERLAND_GERMAN
      Switzerland (German).
    • TAIWAN

      public static final MarketLocale TAIWAN
      Taiwan.
    • TURKEY

      public static final MarketLocale TURKEY
      Turkey.
    • UNITED_KINGDOM

      public static final MarketLocale UNITED_KINGDOM
      United Kingdom.
    • UNITED_STATES_ENGLISH

      public static final MarketLocale UNITED_STATES_ENGLISH
      United States (English).
    • UNITED_STATES_SPANISH

      public static final MarketLocale UNITED_STATES_SPANISH
      United States (Spanish).
  • Method Details

    • values

      public static MarketLocale[] 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

      public static MarketLocale valueOf(String name)
      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 name
      NullPointerException - if the argument is null
    • value

      public String value()
      Description copied from interface: BraveAPIConstant
      Returns the value of the constant. Must be implemented by the enum constants.
      Specified by:
      value in interface BraveAPIConstant
      Returns:
      the value of the constant
    • urlParam

      @NotNull public @NotNull String urlParam()
      Description copied from interface: BraveAPIConstant
      Returns 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 parameterValue may 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:
      urlParam in interface BraveAPIConstant
      Returns:
      the URL parameter associated with this constant
      See Also:
    • toSearchOption

      @Contract(" -> new") @NotNull public @NotNull @Unmodifiable SearchOptionCarrier<String> toSearchOption()
      Description copied from interface: RegionLocaleIdentifier
      Converts this region-locale identifier to a SearchOptionCarrier for use in a search request.
      Specified by:
      toSearchOption in interface ProvidedOption
      Specified by:
      toSearchOption in interface RegionLocaleIdentifier
      Returns:
      the SearchOptionCarrier representing this region-locale