Type Property

mediaServicesWereLostNotification

A notification that’s posted when the system terminates the media server.

Declaration

class let mediaServicesWereLostNotification: NSNotification.Name

Discussion

The system posts this notification when the media server first becomes unavailable. Most apps don’t need to subscribe to this notification and should instead subscribe to the mediaServicesWereResetNotification notification. However, you can use this notification as a cue to take any appropriate steps to handle requests that come in before the server restarts.

This notification has no userInfo dictionary.

The system posts this notification on the main thread.

See Also

Responding to Audio Session Notifications

Responding to Audio Session Interruptions

Observe audio session notifications to ensure that your app responds appropriately to interruptions.

Responding to Audio Session Route Changes

Observe audio session notifications to ensure that your app responds appropriately to route changes.

class let interruptionNotification: NSNotification.Name

A notification that’s posted when an audio interruption occurs.

class let routeChangeNotification: NSNotification.Name

A notification that’s posted when the system’s audio route changes.

class let silenceSecondaryAudioHintNotification: NSNotification.Name

A notification that’s posted when the primary audio from other applications starts and stops.

class let mediaServicesWereResetNotification: NSNotification.Name

A notification that’s posted when the media server restarts.