UNotificationChannel class

An Android notification channel (sound, vibration and importance are fixed per channel).

Annotations

Constructors

UNotificationChannel({required String id, required String name, String? description, UNotificationImportance importance = UNotificationImportance.normal, String? sound, bool vibration = true, List<int>? vibrationPattern, int? lightColor, bool showBadge = true, bool bypassDnd = false, UNotificationVisibility visibility = UNotificationVisibility.private, String? group})
const

Properties

bypassDnd → bool
Rings in Do Not Disturb (needs user permission).
final
description → String?
Description shown in system settings.
final
group → String?
Channel group id (see UNotificationChannelGroup).
final
hashCode → int
The hash code for this object.
no setterinherited
id → String
Channel id (use in requests).
final
importance → UNotificationImportance
How loud it is.
final
lightColor → int?
LED color.
final
name → String
Name shown in system settings.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
showBadge → bool
Adds to the icon badge.
final
sound → String?
res/raw sound name without extension; "none" for silent.
final
vibration → bool
Vibrates.
final
vibrationPattern → List<int>?
Milliseconds: off, on, off, on, …
final
visibility → UNotificationVisibility
What shows on the lock screen.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toMap() → Map<String, Object?>
As a map.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited