-
- All Implemented Interfaces:
public interface RoutesController
-
-
Method Summary
Modifier and Type Method Description abstract StringaddRouteLine(RouteLine routeLine)Add a route on MapView with its rendering options. abstract List<String>addRouteLines(List<RouteLine> routeLines)Add list of routes on MapView with their rendering options. abstract Unitremove(String routeID)Remove Route from current MapView abstract Unitclear()abstract UnitupdateRouteProgress(String routeID)abstract Camera.Regionregion(List<String> routeIDs)Get the region that encompasses the given routes abstract Stringrefresh(RouteLine routeLine)Refresh Route with its rendering options. abstract StringrefreshAlongRouteTraffic(AlongRouteTraffic alongRouteTraffic)abstract Unithighlight(String routeID)Highlight Route, only one route is allowed to be highlighted at once. abstract UnitunHighlight()Unhighlight the existing highlighted route. abstract LocationgetLastEatenRoutePoint(String routeID)Get the last eaten route point abstract BooleanshowTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)show the specified(through selectLegIndex, selectStepIndex) turn arrow on route abstract BooleanhideTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)hide a specified turn arrow from route abstract BooleanhideAllTurnArrows()hides all currently visible turn arrows abstract BooleanmoveToTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)moves the camera to a specified turn arrow, call showTurnArrow first -
-
Method Detail
-
addRouteLine
abstract String addRouteLine(RouteLine routeLine)
Add a route on MapView with its rendering options. This is the recommended way to add a route with custom rendering options. Use RouteLine.builder to create route line with Builder pattern.
- Parameters:
routeLine- route line containing a route and its rendering options
-
addRouteLines
abstract List<String> addRouteLines(List<RouteLine> routeLines)
Add list of routes on MapView with their rendering options. This is the recommended way to add multiple routes with custom rendering options. Use RouteLine.builder to create route lines with Builder pattern.
- Parameters:
routeLines- list of route lines, each containing a route and its rendering options
-
remove
abstract Unit remove(String routeID)
Remove Route from current MapView
- Parameters:
routeID- the route's ID used to remove it from the map
-
updateRouteProgress
abstract Unit updateRouteProgress(String routeID)
Call this function to hide sections of the route that the vehicle has already passed. The function only needs to be called once.
- Parameters:
routeID- the route to be updated.
-
region
abstract Camera.Region region(List<String> routeIDs)
Get the region that encompasses the given routes
- Parameters:
routeIDs- list of routes you want to show
-
refresh
abstract String refresh(RouteLine routeLine)
Refresh Route with its rendering options. This is the recommended way to refresh a route with custom rendering options. Use RouteLine.builder to create route line with Builder pattern.
- Parameters:
routeLine- route line containing a route and its rendering options
-
refreshAlongRouteTraffic
abstract String refreshAlongRouteTraffic(AlongRouteTraffic alongRouteTraffic)
Refresh alongRouteTraffic
- Parameters:
alongRouteTraffic- alongRouteTraffic info from drive session callback NavigationEventListener onAlongRouteTrafficUpdated
-
highlight
abstract Unit highlight(String routeID)
Highlight Route, only one route is allowed to be highlighted at once.
- Parameters:
routeID- specify the route to be highlighted.
-
unHighlight
abstract Unit unHighlight()
Unhighlight the existing highlighted route.
-
getLastEatenRoutePoint
abstract Location getLastEatenRoutePoint(String routeID)
Get the last eaten route point
- Parameters:
routeID- specify the route
-
showTurnArrow
abstract Boolean showTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)
show the specified(through selectLegIndex, selectStepIndex) turn arrow on route
- Parameters:
routeName- the name of the route to show turn arrow onselectLegIndex- the leg index in the routeselectStepIndex- the step index in the route
-
hideTurnArrow
abstract Boolean hideTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)
hide a specified turn arrow from route
- Parameters:
routeName- the name of the route to hide turn arrow onselectLegIndex- the leg index in the routeselectStepIndex- the step index in the route
-
hideAllTurnArrows
abstract Boolean hideAllTurnArrows()
hides all currently visible turn arrows
-
moveToTurnArrow
abstract Boolean moveToTurnArrow(String routeName, Integer selectLegIndex, Integer selectStepIndex)
moves the camera to a specified turn arrow, call showTurnArrow first
- Parameters:
routeName- the name of the route to move to turn arrowselectLegIndex- the leg index in the routeselectStepIndex- the step index in the route
-
-
-
-