VMERouteRequest

class VMERouteRequest(requestType: VMERouteRequestType, routeDestinationOrder: VMERouteDestinationsOrder, isAccessible: Boolean, animateAllRoute: Boolean, distanceThreshold: Double)

Represents an instance of route request

Since

1.19

Parameters

requestType

Determines the type of request

routeDestinationOrder

Determines the visiting order of the destination objects

Notes

By default:

  • VMERouteRequest.isAccessible() will return false.

Constructors

Link copied to clipboard
fun VMERouteRequest(requestType: VMERouteRequestType, routeDestinationOrder: VMERouteDestinationsOrder, isAccessible: Boolean = false, animateAllRoute: Boolean = false, distanceThreshold: Double = -1.0)

Functions

Link copied to clipboard
fun addDestination(position: VMEPosition)

Adds a position object to the end of the destinations array’s content.

fun addDestination(poiID: String)

Adds a destination to the request.

Link copied to clipboard
fun addDestinations(destinations: Collection<Any>)

Adds the objects contained in the given array to the end of the destinations array’s content.

Link copied to clipboard
fun removeAllDestinations()

Remove all destinations objects from the destination array.

Link copied to clipboard
fun removeDestinationAtIndex(index: Int)

Remove destination object at the given index

Link copied to clipboard
fun replaceDestination(index: Int, destination: Any)

Repois the destination object at the given index with the given destination.

Link copied to clipboard
fun setOrigin(position: VMEPosition?)

The position representing the origin of the route.

fun setOrigin(poiID: String?)

The poi id representing the origin of the route.

Properties

Link copied to clipboard
var animateAllRoute: Boolean = false

If we want to animate all the route

Link copied to clipboard
val distanceThreshold: Double

distanceThreshold is used to force a max distance between position given and nearest node if specified, the routing will take this value to search for nearest nodes within this range if not specified, there will be not distance limit to search for a node

Link copied to clipboard
var isAccessible: Boolean = false

Requests that the computed route is accessible.

Link copied to clipboard
val mDestinations: <ERROR CLASS><Any>

Ordered array of String objects, where each object must correspond to a poi Id

Link copied to clipboard
var origin: Any? = null

The poi id or location representing the origin of the route.

Link copied to clipboard
var requestType: VMERouteRequestType

The desired route request type.

Link copied to clipboard
var routeDestinationOrder: VMERouteDestinationsOrder

Sets the route destination order.