Partager via


UIApplication.RegisterUserNotificationSettings Méthode

Définition

Inscrit les options préférées pour la notification à l’utilisateur.

[Foundation.Export("registerUserNotificationSettings:")]
[ObjCRuntime.Deprecated(ObjCRuntime.PlatformName.iOS, 10, 0, ObjCRuntime.PlatformArchitecture.None, "Use 'UNUserNotificationCenter.RequestAuthorization' and 'UNUserNotificationCenter.SetNotificationCategories' instead.")]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 8, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Unavailable(ObjCRuntime.PlatformName.TvOS, ObjCRuntime.PlatformArchitecture.All, null)]
public virtual void RegisterUserNotificationSettings (UIKit.UIUserNotificationSettings notificationSettings);
abstract member RegisterUserNotificationSettings : UIKit.UIUserNotificationSettings -> unit
override this.RegisterUserNotificationSettings : UIKit.UIUserNotificationSettings -> unit

Paramètres

notificationSettings
UIUserNotificationSettings

Types de notification que l’application souhaite utiliser.

Attributs

Remarques

Cette opération affiche, si nécessaire, une boîte de dialogue de confidentialité standard. Une fois que l’utilisateur interagit avec celui-ci, M M:UIKit.UIApplicationDelegate.DidRegisterUserNotifications* est appelé.

S’applique à