FlutterNotificationChannel class
Properties
-
hashCode
→ int
-
The hash code for this object.
no setterinherited
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
toString()
→ String
-
A string representation of this object.
inherited
Static Methods
-
registerNotificationChannel({required String id, required String name, required String description, required int importance, int visibility = NotificationVisibility.VISIBILITY_PUBLIC, bool allowBubbles = true, bool enableVibration = true, bool enableSound = true, bool showBadge = true})
→ Future<String>
-
id
The id of the channel. Must be unique per package.
The value may be truncated if it is too long
name
The user visible name of the channel.
The recommended maximum length is 40 characters; the value may be
truncated if it is too long
description
Sets the user visible description of this channel.
The recommended maximum length is 300 characters;
the value may be truncated if it is too long
importance
The importance of the channel.
This controls how interruptive notifications posted to this channel are
it is one of the constants from NotificationImportance class
visibility
Sets whether notifications posted to this channel appear on the lockscreen or not, and if so,
whether they appear in a redacted form. See e.g.
Only modifiable by the system and notification ranker
allowBubble
IMPORTANT! Will take effect only on sdk version 29+
and will be silently ignored on any prior versions
Sets whether notifications posted to this
channel can appear outside of the notification
shade, floating over other apps' content as a bubble.