Match

extension Match
  • Returns a polyline extending a given distance in either direction from a given maneuver along the route.

    The maneuver is identified by a leg index and step index, in case the route doubles back on itself.

    Declaration

    Swift

    func polylineAroundManeuver(legIndex: Int, stepIndex: Int, distance: CLLocationDistance) -> LineString

    Parameters

    legIndex

    Zero-based index of the leg containing the maneuver.

    stepIndex

    Zero-based index of the step containing the maneuver.

    distance

    Distance by which the resulting polyline extends in either direction from the maneuver.

    Return Value

    A polyline whose length is twice distance and whose centroid is located at the maneuver.