SearchResult

public struct SearchResult

SearchResult Object containing grouped information about places or points of interest.

Important

This is a Public Preview API. It may be changed or removed at any time.

Lifecycle

  • SearchResult init method.

    Declaration

    Swift

    public init(
        type: SearchResultType,
        searchResultID: SearchResultID,
        distance: Measurement<UnitLength>?,
        poi: POI?,
        address: Address,
        position: CLLocationCoordinate2D,
        mapCodes: [MapCode],
        boundingBox: BoundingBox?,
        detourTime: Measurement<UnitDuration>?,
        detourDistance: Measurement<UnitLength>?,
        detourOffset: Measurement<UnitLength>?
    )

    Parameters

    type

    The type of result

    searchResultID

    The ID of the result.

    distance

    The distance from the route provided in the request.

    poi

    Information about the POI.

    address

    Detailed address of the result.

    position

    The geographical position of the POI.

    boundingBox

    The bounding box of the result.

    byDetourTime

    The detour duration for a passenger car in seconds. The detour duration is the value added to the estimated time of arrival (to the final destination), after a point of interest has been added to the route.

    byDetourDistance

    The detour [Distance] is the added value to the route length, after a point of interest has been added to the route.

    detourOffset

    The length of the route part from the starting point to the detour starting point.

Public

  • The type of result.

    Declaration

    Swift

    public let type: SearchResultType
  • The ID of the result.

    Declaration

    Swift

    public let searchResultID: SearchResultID
  • The distance from the route provided in the request.

    Declaration

    Swift

    public let distance: Measurement<UnitLength>?
  • poi

    Information about the POI.

    Declaration

    Swift

    public let poi: POI?
  • Detailed address of the result.

    Declaration

    Swift

    public let address: Address
  • The geographical position of the POI.

    Declaration

    Swift

    public let position: CLLocationCoordinate2D
  • A list of MapCode objects.

    Declaration

    Swift

    public let mapCodes: [MapCode]
  • The bounding box of the result.

    Declaration

    Swift

    public let boundingBox: BoundingBox?
  • The detour duration for a passenger car in seconds. The detour duration is the value added to the estimated time of arrival (to the final destination), after a point of interest has been added to the route.

    Declaration

    Swift

    public let detourTime: Measurement<UnitDuration>?
  • The detour [Distance] is the added value to the route length, after a point of interest has been added to the route.

    Declaration

    Swift

    public let detourDistance: Measurement<UnitLength>?
  • The length of the route part from the starting point to the detour starting point.

    Declaration

    Swift

    public let detourOffset: Measurement<UnitLength>?