Layer that renders a route on the map as traveled and remaining polylines. More...
Inheritance diagram for com.navigine.idl.java.RouteLayer:Public Member Functions | |
| abstract void | setVisible (boolean visible) |
| Shows or hides the route layer. | |
| abstract boolean | isVisible () |
| Returns true if the route layer is visible. | |
| abstract void | setTarget (RouteEndpoint target) |
| Starts turn-by-turn guidance to the target from the current position. | |
| abstract void | setRoute (RouteEndpoint from, RouteEndpoint to) |
| Builds and shows a static route between two points (no live guidance). | |
| abstract void | clear () |
| Cancels guidance / static route and removes polylines from the map. | |
| abstract ArrayList< RouteView > | routes () |
| Returns currently rendered routes. V1 exposes a single active route. | |
| abstract RouteView | selectedRoute () |
| Returns selected route view, or null when no route is selected. | |
| abstract void | selectRoute (RouteView route) |
| Selects the provided route view. Pass null to clear selection. | |
| abstract void | addRouteLayerListener (RouteLayerListener listener) |
| Adds listener for route lifecycle, progress and target reach events. | |
| abstract void | removeRouteLayerListener (RouteLayerListener listener) |
| Removes previously added route layer listener. | |
| abstract void | addRouteViewListener (RouteViewListener listener) |
| Adds listener for route view list, selection and tap events. | |
| abstract void | removeRouteViewListener (RouteViewListener listener) |
| Removes previously added route view listener. | |
| abstract void | setTraveledColor (int color) |
| Sets traveled (passed) route polyline color. | |
| abstract void | setRemainingColor (int color) |
| Sets remaining route polyline color. | |
| abstract void | setWidth (float width) |
| Sets route polyline width in pixels (also used as default dotted point size). | |
| abstract void | setRemainingStyle (RouteRemainingStyle style) |
| Sets rendering style for the remaining route. | |
| abstract RouteRemainingStyle | remainingStyle () |
| Returns the remaining route rendering style. | |
| abstract void | setRemainingDashLength (float dashLength) |
| Sets dash length for DASHED remaining style. Use 0 to disable dashing. | |
| abstract void | setRemainingGapLength (float gapLength) |
| Sets gap length for DASHED remaining style. Use 0 to disable dashing. | |
| abstract void | setRemainingPointSize (float width, float height) |
| Sets point size for DOTTED remaining style. | |
| abstract void | setRemainingPlacement (Placement placement) |
| Sets point placement mode for DOTTED remaining style. | |
| abstract void | setRemainingPlacementSpacing (float spacing) |
| Sets spacing between points for DOTTED + SPACED placement (pixels). | |
| abstract void | setRemainingPlacementMinRatio (float ratio) |
| Sets minimum polyline length ratio for DOTTED placement. | |
| abstract void | setRemainingCollisionEnabled (boolean enabled) |
| Enables or disables collision for DOTTED remaining points. | |
| abstract boolean | isValid () |
Layer that renders a route on the map as traveled and remaining polylines.
Independent from UserLocationLayer: a route can be shown without a user marker, and a user marker can be shown without a route.
Location and position are taken from the SDK automatically (same pattern as UserLocationLayer).
Referenced from NavigineSdk.
Definition at line 26 of file RouteLayer.java.
|
abstract |
Adds listener for route lifecycle, progress and target reach events.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Adds listener for route view list, selection and tap events.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Cancels guidance / static route and removes polylines from the map.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Tells if this RouteLayer is valid or not. Any other method (except for this one) called on an invalid RouteLayer will throw java.lang.RuntimeException.
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Returns true if the route layer is visible.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Returns the remaining route rendering style.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Removes previously added route layer listener.
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Removes previously added route view listener.
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Returns currently rendered routes. V1 exposes a single active route.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Returns selected route view, or null when no route is selected.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Selects the provided route view. Pass null to clear selection.
| route | Route view from routes, or null. |
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Enables or disables collision for DOTTED remaining points.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets remaining route polyline color.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets dash length for DASHED remaining style. Use 0 to disable dashing.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets gap length for DASHED remaining style. Use 0 to disable dashing.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets point placement mode for DOTTED remaining style.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets minimum polyline length ratio for DOTTED placement.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets spacing between points for DOTTED + SPACED placement (pixels).
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets point size for DOTTED remaining style.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets rendering style for the remaining route.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Builds and shows a static route between two points (no live guidance).
| from | Route start endpoint. |
| to | Route finish endpoint. |
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Starts turn-by-turn guidance to the target from the current position.
| target | Destination endpoint. Route and progress are updated automatically. |
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets traveled (passed) route polyline color.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Shows or hides the route layer.
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.
|
abstract |
Sets route polyline width in pixels (also used as default dotted point size).
Java code snippet:
Kotlin code snippet:
Reimplemented in com.navigine.idl.java.internal.RouteLayerBinding.