Contents

DDEventHandler

A function that the extension invokes to signal an event.

Declaration

typealias DDEventHandler = (DDDeviceEvent) -> Void

Parameters

  • inEvent:

    An event that the extension creates for the event handler.

Discussion

A device discovery extension implements a closure of this format and calls it after creating argument events. In the implementation, the extension creates device events (DDEvent) and passes them to the system by calling report(_:).

For an example event handler, see Appex.swift in Discovering a third-party media-streaming device.

See Also

Life cycle