MapboxRouteLineApiExtensions
Extension functions for MapboxRouteLineApi calls that are implemented as callbacks. This offers an alternative to those callbacks by providing Kotlin oriented suspend functions.
Functions
Clears the route line data.
The map will be queried for a route line feature at the target point or a bounding box centered at the target point with a padding value determining the box's size. If a route feature is found the index of that route in this class's route collection is returned. The primary route is given precedence if more than one route is found.
Overrides the color Expression for the alternative traffic lines with the Expression provided. If the Expected is an error the same Expected object is returned.
Overrides the color Expression for the alternative traffic lines with the color indicated. The entire traffic line will take on the color provided. If the Expected is an error the same Expected object is returned.
Sets the routes that will be operated on.
Sets the routes that will be operated on.
Overrides the color Expression for the primary traffic line with the Expression provided. If the Expected is an error the same Expected object is returned.
Overrides the color Expression for the primary traffic line with the color indicated. The entire traffic line will take on the color provided. If the Expected is an error the same Expected object is returned.
Sets the routes that will be operated on.
If successful this method returns a RouteLineUpdateValue that when rendered will display the route line with the route leg indicated by the provided leg index highlighted. All the other legs will only show a simple line with RouteLineColorResources.inActiveRouteLegsColor.