NotificationChannel Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
NotificationChannel(String, ICharSequence, NotificationImportance) |
Creates a notification channel. |
NotificationChannel(String, String, NotificationImportance) |
NotificationChannel(String, ICharSequence, NotificationImportance)
Creates a notification channel.
[Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/lang/CharSequence;I)V", "", ApiSince=26)]
public NotificationChannel (string? id, Java.Lang.ICharSequence? name, Android.App.NotificationImportance importance);
[<Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/lang/CharSequence;I)V", "", ApiSince=26)>]
new Android.App.NotificationChannel : string * Java.Lang.ICharSequence * Android.App.NotificationImportance -> Android.App.NotificationChannel
Parameters
- id
- String
The id of the channel. Must be unique per package. The value may be truncated if it is too long.
- name
- ICharSequence
The user visible name of the channel. You can rename this channel when the system
locale changes by listening for the Intent#ACTION_LOCALE_CHANGED
broadcast. The recommended maximum length is 40 characters; the value may be
truncated if it is too long.
- importance
- NotificationImportance
The importance of the channel. This controls how interruptive notifications posted to this channel are.
- Attributes
Remarks
Creates a notification channel.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Applies to
NotificationChannel(String, String, NotificationImportance)
[Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/lang/CharSequence;I)V", "", ApiSince=26)]
public NotificationChannel (string? id, string? name, Android.App.NotificationImportance importance);
[<Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/lang/CharSequence;I)V", "", ApiSince=26)>]
new Android.App.NotificationChannel : string * string * Android.App.NotificationImportance -> Android.App.NotificationChannel
Parameters
- id
- String
- name
- String
- importance
- NotificationImportance
- Attributes
Remarks
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.