search

abstract fun search(query: String, options: OfflineSearchOptions, executor: Executor, callback: OfflineSearchCallback): AsyncOperationTask

Performs forward geocoding search request. Each new search request cancels the previous one if it is still in progress. In this case OfflineSearchCallback.onError will be called with com.mapbox.search.common.SearchCancellationException.

Return

AsyncOperationTask object which allows to cancel the request.

Parameters

query

Search query.

options

Search options.

executor

Executor used for events dispatching. By default events are dispatched on the main thread.

callback

The callback to handle search result.


open fun search(query: String, options: OfflineSearchOptions, callback: OfflineSearchCallback): AsyncOperationTask

Performs forward geocoding search request. Each new search request cancels the previous one if it is still in progress. In this case OfflineSearchCallback.onError will be called with com.mapbox.search.common.SearchCancellationException.

Return

AsyncOperationTask object which allows to cancel the request.

Parameters

query

Search query.

options

Search options.

callback

The callback to handle search result on the main thread.