AlongRouteSearchOptions

data class AlongRouteSearchOptions(val route: List<GeoPoint>, val maxDetourDuration: Duration, val query: String = "", @IntRange(from = 1, to = 20) val limit: Int = 10, val categoryIds: Set<CategoryId> = emptySet(), val brands: Set<Brand> = emptySet(), val fuelTypes: Set<FuelType> = emptySet(), val connectorTypes: Set<ConnectorType> = emptySet(), val minPower: Power? = null, val maxPower: Power? = null, val geoPoliticalView: GeoPoliticalView? = null, val sortBy: SortBy = SortBy.DetourTime, val openingHoursMode: OpeningHoursMode = OpeningHoursMode.NextSevenDays, val sessionId: String = "")

Defines the parameters for the Search Along the Route query.

Important: This is a Public Preview API. It may be changed or removed at any time.

See also

Supported connector types[https://developer.tomtom.com/search-api/search-api-documentation/supported-connector-types] for more details.

Parameters

route

The route points define the skeleton of the search area.

maxDetourDuration

The maximum detour duration (for a passenger car) limits the search area. The detour duration is the value added to the estimated time of arrival (to the final destination) after a point of interest is added to the route. Search results that add more than this value are filtered out. The maximum accepted value is 3600 seconds. If a value greater than the maximum is provided then the maximum value is used.

query

The search query.

limit

The maximum number of search results that will be returned.

categoryIds

Restricts the Points Of Interest in the response to those whose category ID is listed.

brands

Brand names are used to restrict the result to POIs associated with those brands.

fuelTypes

A set of FuelTypes, used to restrict the results to fuel stations with at least one of the specified fuel types.

connectorTypes

Connector types are used to restrict the results to electric vehicle stations that support those connector types.

minPower

A power rate, used to restrict the results to electric vehicle stations with at least one connector that has a power greater or equal to that minimum power.

maxPower

A power rate, used to restrict the results to electric vehicle stations with at least one connector that has a power lesser or equal to that maximum power.

geoPoliticalView

Defines what kind of geopolitical view should be used.

sortBy

Defines how the results will be sorted.

openingHoursMode

Scope of the opening hours to be provided.

sessionId

The ID of a user session during which a user performs multiple search requests to find a specific address or point of interest. This parameter is used for sending anonymous feedback to the online search for the search quality improvement.

Constructors

Link copied to clipboard
fun AlongRouteSearchOptions(route: List<GeoPoint>, maxDetourDuration: Duration, query: String = "", @IntRange(from = 1, to = 20) limit: Int = 10, categoryIds: Set<CategoryId> = emptySet(), brands: Set<Brand> = emptySet(), fuelTypes: Set<FuelType> = emptySet(), connectorTypes: Set<ConnectorType> = emptySet(), minPower: Power? = null, maxPower: Power? = null, geoPoliticalView: GeoPoliticalView? = null, sortBy: SortBy = SortBy.DetourTime, openingHoursMode: OpeningHoursMode = OpeningHoursMode.NextSevenDays, sessionId: String = "")

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val limit: Int = 10
Link copied to clipboard
Link copied to clipboard
val maxPower: Power? = null
Link copied to clipboard
val minPower: Power? = null
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard