Type Alias

CHHapticEngine.StoppedHandler

A typealias for the block that the haptic engine calls after it stops due to external causes.

Declaration

typealias StoppedHandler = (CHHapticEngine.StoppedReason) -> Void

Discussion

For example, audio session interruption. Any reason other than when you explicitly ask it to stop. If you call stop, this won't fire. Otherwise, stoppedHandler will be called.

See Also

Handling Haptic Engine Stoppages

var stoppedHandler: CHHapticEngine.StoppedHandler

A block that the haptic engine calls when it stops due to external causes.

enum CHHapticEngine.StoppedReason

An enumeration of possible reasons the haptic engine stopped running.