Contents

CMAltitudeHandler

A block for receiving relative altitude data.

Declaration

typealias CMAltitudeHandler = (CMAltitudeData?, (any Error)?) -> Void

Parameters

  • altitudeData:

    The relative change in altitude data. If there’s an error generating the data, this parameter is nil.

  • error:

    The error object. Returns nil if the altimeter successfully delivers the altitude data. When an error occurs, you can use the information in the provided object to recover the data or to alert the user.

Discussion

You pass a block of this type to the altimeter object’s startRelativeAltitudeUpdates(to:withHandler:) method when starting the delivery of altitude data.

See Also

Starting and Stopping Altitude Updates