• public final class TransitRoutingEngine
    extends NativeBase

    Use the TransitRoutingEngine to calculate a public transit route from A to B with a number of waypoints in between. Route calculation is done asynchronously and requires an online connection. The resulting route contains various information such as the polyline, route length in meters, estimated time to traverse along the route and maneuver data.

    • Method Detail

      • calculateRoute

        @NonNull
        public TaskHandle calculateRoute​(@NonNull
                                         TransitWaypoint startingPoint,
                                         @NonNull
                                         TransitWaypoint destination,
                                         @NonNull
                                         TransitRouteOptions routeOptions,
                                         @NonNull
                                         CalculateRouteCallback callback)

        Asynchronously calculates a public transit route from the origin to the destination.

        Parameters:
        startingPoint -

        Position of starting point.

        destination -

        Position of destination.

        routeOptions -

        Options for public transit route calculation.

        callback -

        Callback object that will be invoked after route calculation. It is always invoked on the main thread.

        Returns:

        Handle that will be used to manipulate the execution of the task.