Contents

insertRouteData(_:completion:)

Adds route data to the builder.

Declaration

func insertRouteData(_ routeData: [CLLocation], completion: @escaping  @Sendable (Bool, (any Error)?) -> Void)
func insertRouteData(_ routeData: [CLLocation]) async throws

Parameters

  • routeData:

    An array containing one or more location objects.

  • completion:

    A block called after the system adds the collection data to the builder. The system passes the block the following parameters:

    success

    A Boolean value that indicates whether the builder successfully received the route data.

    error

    An object that describes the error, if an error has occurred; otherwise, nil.

Mentioned in

Discussion

Use this method to asynchronously add one or more CLLocation objects to the series. The CLLocation objects may be inserted in any order; the builder sorts them by date when finalizing the route.

See Also

Building the route