MatchOptions
open class MatchOptions : DirectionsOptionsA MatchOptions object is a structure that specifies the criteria for results returned by the Mapbox Map Matching API.
Pass an instance of this class into the Directions.calculate(_:completionHandler:) method.
- 
                  
                  Initializes a match options object for matching locations against the road network. DeclarationSwift public convenience init(locations: [CLLocation], profileIdentifier: DirectionsProfileIdentifier? = nil)ParameterslocationsAn array of CLLocationobjects representing locations to attempt to match against the road network. The array should contain at least two locations (the source and destination) and at most 100 locations. (Some profiles, such asDirectionsProfileIdentifier.automobileAvoidingTraffic, may have lower limits.)profileIdentifierA string specifying the primary mode of transportation for the routes. DirectionsProfileIdentifier.automobileis used by default.
- 
                  
                  Initializes a match options object for matching geographic coordinates against the road network. DeclarationSwift public convenience init(coordinates: [CLLocationCoordinate2D], profileIdentifier: DirectionsProfileIdentifier? = nil)ParameterscoordinatesAn array of geographic coordinates representing locations to attempt to match against the road network. The array should contain at least two locations (the source and destination) and at most 100 locations. (Some profiles, such as DirectionsProfileIdentifier.automobileAvoidingTraffic, may have lower limits.) Each coordinate is converted into aWaypointobject.profileIdentifierA string specifying the primary mode of transportation for the routes. DirectionsProfileIdentifier.automobileis used by default.
- 
                  
                  DeclarationSwift public required init(waypoints: [Waypoint], profileIdentifier: DirectionsProfileIdentifier? = nil)
- 
                  
                  If true, the input locations are re-sampled for improved map matching results. The default is false.DeclarationSwift open var resamplesTraces: Bool
- 
                  
                  An index set containing indices of two or more items in coordinates. These will be represented byWaypoints in the resultingMatchobjects.Use this property when the DirectionsOptions.includesStepsproperty istrueor whencoordinatesrepresents a trace with a high sample rate. If this property isnil, the resultingMatchobjects contain a waypoint for each coordinate in the match options.If specified, each index must correspond to a valid index in coordinates, and the index set must contain 0 and the last index (one less thanendIndex) ofcoordinates.DeclarationSwift @available(*, deprecated, message: "Use Waypoint.separatesLegs instead.") open var waypointIndices: IndexSet?
- 
                  
                  DeclarationSwift override open var urlQueryItems: [URLQueryItem] { get }
 Install in Dash
              Install in Dash
             MatchOptions Class Reference
        MatchOptions Class Reference