Instance Property

soundSetting

The authorization status for playing sounds for incoming notifications.

Declaration

var soundSetting: UNNotificationSetting { get }

Discussion

When the value of this property is UNNotificationSetting.enabled, the app is authorized to play sounds. The system tries to play a sound when the sound property of the UNNotificationContent object contains a value, or when the aps dictionary in a remote notification contains the sound key.

See Also

Getting Device-Specific Settings

var notificationCenterSetting: UNNotificationSetting

The setting that indicates whether your app’s notifications are displayed in Notification Center.

var lockScreenSetting: UNNotificationSetting

The setting that indicates whether your app’s notifications appear onscreen when the device is locked.

var carPlaySetting: UNNotificationSetting

The setting that indicates whether your app’s notifications may be displayed in a CarPlay environment.

var alertSetting: UNNotificationSetting

The authorization status for displaying alerts.

var badgeSetting: UNNotificationSetting

The authorization status for badging your app’s icon.

var criticalAlertSetting: UNNotificationSetting

The authorization status to play sounds for critical alerts.

enum UNNotificationSetting

Constants indicating the current status of a notification setting.