AutocompleteOptions

data class AutocompleteOptions(val query: String, val locale: Locale = Locale.getDefault(), @IntRange(from = 1, to = 10) val limit: Int = DEFAULT_LIMIT, val position: GeoPoint? = null, val radius: Distance? = null, val countries: Set<String> = emptySet(), val resultTypes: Set<AutoCompleteResultType> = emptySet(), val sessionId: UUID? = null)

Contains the parameters to use in an autocomplete search.

Constructors

Link copied to clipboard
constructor(query: String, locale: Locale = Locale.getDefault(), @IntRange(from = 1, to = 10) limit: Int = DEFAULT_LIMIT, position: GeoPoint? = null, radius: Distance? = null, countries: Set<String> = emptySet(), resultTypes: Set<AutoCompleteResultType> = emptySet(), sessionId: UUID? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

A set of ISO 3166-1 alpha3 country codes. (e.g., FRA,ESP). This limits the autocomplete results to the specified countries.

Link copied to clipboard
val limit: Int

The maximum number of autocomplete results that will be returned. It defaults to DEFAULT_LIMIT. The maximum value for limit is MAX_LIMIT_VALUE.

Link copied to clipboard

The language in which search results should be returned. If not specified, language is set to the system default language.

Link copied to clipboard
val position: GeoPoint? = null

The position around which results should be biased.

Link copied to clipboard

The search query.

Link copied to clipboard
val radius: Distance? = null

The search radius in meters.

Link copied to clipboard

Restricts the results to a specific result type. Valid result types are AutoCompleteResultType.Category and AutoCompleteResultType.Brand. An empty set implies restricting search results to both brand and category suggestions.

Link copied to clipboard
val sessionId: UUID? = null

A search session is a user session during which a user performs multiple search requests to find a specific address ot point of interest. This is needed for sending feedback to the online search. It must be a valid UUIDv4. If it is not provided, no feedback is sent.