awesome_notifications library

Classes

AwesomeAssertUtils
AwesomeBitmapUtils
AwesomeDateUtils
AwesomeMapUtils
AwesomeNotifications
AwesomeStringUtils
BitmapHelper
EXTRACTED FROM bitmap: ^0.0.6 DUE TO BUILD GRADLE INCOMPATIBILITIES
CronHelper
Cron helper to set notification repetitions Use the rule bellow to specify your on cron repetition rule or access the website https://www.baeldung.com/cron-expressions to see more details.
Definitions
Emojis
List of ASCII emojis
MediaSourcePrefix
Media source prefix, to identify which treatment should be done to each file path
NotificationActionButton
Represents a button to be displayed inside a notification. Note: Since Android 7, icons are only displayed for Media Layout Notifications. The icon must be a native resource media type.
NotificationAndroidCrontab
(Only for Android devices) Represents a notification scheduling configuration based on crontab rules or a list of valid dates.
NotificationCalendar
Represents a notification scheduling configuration based on calendar components.
NotificationChannel
Represents default settings applied to all notifications sharing the same channel key. Note: The soundSource needs to be a native resource media type.
NotificationChannelGroup
Represents a group of notification channels to be displayed at Android Notification Settings Page.
NotificationContent
Represents the content of a notification with customizable options. If notification has no body or title, it will only be created, but not displayed to the user (background notification).
NotificationInterval
Represents a notification scheduling configuration based on time intervals.
NotificationLocalization
A model class that represents a set of localized strings for a notification, including the title, body, summary, large icon, big picture, and button labels.
NotificationModel
A model class representing a single notification instance.
NotificationSchedule
Abstract base class for notification schedule configuration. Defines the common properties and methods for scheduling notifications.
PushNotification
ReceivedAction
All received details of a user action over a Notification
ReceivedNotification
All received details of a notification created or displayed on the system The data field
ResourceImage
Decodes the given Uint8List buffer as an image, associating it with the given scale.
RGBA32BitmapHeader

Enums

ActionType
Defines the notification button's type ActionType.Default Is the default action type, forcing the app to goes foreground. ActionType.SilentAction Do not forces the app to go foreground, but runs on main thread, accept visual elements and can be interrupt if main app gets terminated. ActionType.SilentBackgroundAction Do not forces the app to go foreground and runs on background, not accepting any visual elements. The execution is done on background thread. ActionType.KeepOnTop Fires the respective action without close the notification status bar and don't bring the app to foreground. ActionType.DisabledAction When pressed, the notification just close itself on the tray, without fires any action event. ActionType.DismissAction Behaves as the same way as a user dismissing action, dismissing the respective notification and firing the dismissMethod. Ignores autoDismissible property. ActionType.InputField (Deprecated) When the button is pressed, it opens a dialog shortcut to send an text response.
DefaultRingtoneType
Determines what kind of default sound should be played with the notification Ringtone: Type that refers to sounds that are used for the phone ringer. Notification: Type that refers to sounds that are used for notifications (default). Alarm: Type that refers to sounds that are used for the alarm.
GroupAlertBehavior
Sets the group alert behavior for this notification. Use this method to mute this notification if alerts for this notification's group should be handled by a different notification. This is only applicable for notifications that belong to a group. GroupAlertBehavior.All All notifications in a group with sound or vibration ought to make sound or vibrate (respectively), so this notification will not be muted when it is in a group. GroupAlertBehavior.Summary All children notification in a group should be silenced (no sound or vibration) even if they would otherwise make sound or vibrate. GroupAlertBehavior.Children The summary notification in a group should be silenced (no sound or vibration) even if they would otherwise make sound or vibrate
GroupSort
Determines the grouping sort order GroupSort.Asc Order the notifications inside grouping by ascending order GroupSort.Desc Order the notifications inside grouping by descending order
MediaSource
A reference to where load the media (Image or Sound) to build a notification. There's 4 media types available:
NotificationCategory
One of the predefined notification categories that best describes this Notification. May be used by the system for ranking and filtering.
NotificationImportance
Determines the importance to show immeadetly the notification to the user Default: shows everywhere, makes noise, but does not visually intrude. Higher: shows everywhere, makes noise and peeks. May use full screen intents. Low: Shows in the shade, and potentially in the status bar (see shouldHideSilentStatusBarIcons()), but is not audibly intrusive. Min: only shows in the shade, below the fold. This should not be used with Service#startForeground(int, Notification) since a foreground service is supposed to be something the user cares about so it does not make semantic sense to mark its notification as minimum importance. If you do this as of Android version Build.VERSION_CODES.O, the system will show a higher-priority notification about your app running in the background. None: A notification with no importance: does not show in the shade.
NotificationLayout
Notification Layout to be used as reference to build the notification. If is not possible to build the desired layout, use the default one.
NotificationLifeCycle
Application life cycle at new notification change state
NotificationPermission
Constants for requesting authorization to interact with the user thought notifications Alert Alerts are notifications with high priority that pops up on the user screen. Notifications with normal priority only shows the icon on status bar. Sound Sound allows the ability to play sounds for new displayed notifications. The notification sounds are limited to a few seconds and if you pretend to play a sound for more time, you must consider to play a background sound to do it simultaneously with the notification. Badge Badge is the ability to display a badge alert over the app icon to alert the user about updates. The badges can be displayed on numbers or small dots, depending of platform or what the user defined in the device settings. Both Android and iOS can show numbers on badge, depending of its version and distribution. Light The ability to display colorful small lights, blanking on the device while the screen is off to alert the user about updates. Only a few Android devices have this feature. Vibration The ability to vibrate the device to alert the user about updates. PreciseAlarms Precise alarms allows the scheduled notifications to be displayed at the expected time. This permission can be revoke by special device modes, such as baterry save mode, etc. Some manufactures can disable this feature if they decide that your app is consumpting many computational resources and decressing the baterry life (and without changing the permission status for your app). So, you must take in consideration that some schedules can be delayed or even not being displayed, depending of what platform are you running. You can increase the chances to display the notification at correct time, enable this permission and setting the correct notification category, but you never gonna have 100% sure about it. FullScreenIntent The ability to show the notifications on pop up even if the user is using another app. CriticalAlert Critical alerts is a special permission that allows to play sounds and vibrate for new notifications displayed, even if the device is in Do Not Disturbe / Silent mode. For iOS, you must request Apple a authorization to your app use it. OverrideDnD Override DnD allows the notification to decrease the "Do Not Disturbe"/ Silent mode level enable to display critical alerts for Alarm and Call notifications. For Android, you must require the user consent to use it. For iOS, this permission is always enabled with CriticalAlert. Provisional (Only has effect on iOS) The ability to display notifications for a period of time without the user consent. Car The ability to display notifications while the device is in car mode.
NotificationPlayState
Notification Layout to be used as reference to build the notification. If is not possible to build the desired layout, use the default one.
NotificationPrivacy
Hides sensitive notifications when the device is on lock screen Public: Show this notification in its entirety on all lockscreens Private: Show this notification on all lockscreens, but conceal sensitive or private information on secure lockscreens Secret: Do not reveal any part of this notification on a secure lockscreen
NotificationSource
Enumerates if notification was created on local source, scheduled notification, Firebase, OneSignal, etc.

Constants

ACTION_HANDLE → const String
APP_LIFECYCLE_APP_KILLED → const String
APP_LIFECYCLE_BACKGROUND → const String
APP_LIFECYCLE_FOREGROUND → const String
APR → const String
AUG → const String
BACKGROUND_HANDLE → const String
bitmapPixelLength → const int
BROADCAST_FCM_TOKEN → const String
BROADCAST_MESSAGE → const String
CHANNEL_FLUTTER_PLUGIN → const String
CHANNEL_FORCE_UPDATE → const String
CHANNEL_METHOD_CANCEL_ALL_NOTIFICATIONS → const String
CHANNEL_METHOD_CANCEL_ALL_SCHEDULES → const String
CHANNEL_METHOD_CANCEL_NOTIFICATION → const String
CHANNEL_METHOD_CANCEL_NOTIFICATIONS_BY_CHANNEL_KEY → const String
CHANNEL_METHOD_CANCEL_NOTIFICATIONS_BY_GROUP_KEY → const String
CHANNEL_METHOD_CANCEL_SCHEDULE → const String
CHANNEL_METHOD_CANCEL_SCHEDULES_BY_CHANNEL_KEY → const String
CHANNEL_METHOD_CANCEL_SCHEDULES_BY_GROUP_KEY → const String
CHANNEL_METHOD_CHECK_PERMISSIONS → const String
CHANNEL_METHOD_CLEAR_STORED_ACTION → const String
CHANNEL_METHOD_CREATE_NOTIFICATION → const String
CHANNEL_METHOD_DART_CALLBACK → const String
CHANNEL_METHOD_DECREMENT_BADGE_COUNT → const String
CHANNEL_METHOD_DISMISS_ALL_NOTIFICATIONS → const String
CHANNEL_METHOD_DISMISS_NOTIFICATION → const String
CHANNEL_METHOD_DISMISS_NOTIFICATIONS_BY_CHANNEL_KEY → const String
CHANNEL_METHOD_DISMISS_NOTIFICATIONS_BY_GROUP_KEY → const String
CHANNEL_METHOD_GET_ALL_ACTIVE_NOTIFICATION_IDS → const String
CHANNEL_METHOD_GET_APP_LIFE_CYCLE → const String
CHANNEL_METHOD_GET_BADGE_COUNT → const String
CHANNEL_METHOD_GET_DRAWABLE_DATA → const String
CHANNEL_METHOD_GET_FCM_TOKEN → const String
CHANNEL_METHOD_GET_INITIAL_ACTION → const String
CHANNEL_METHOD_GET_LOCAL_TIMEZONE_IDENTIFIER → const String
CHANNEL_METHOD_GET_LOCALIZATION → const String
CHANNEL_METHOD_GET_NEXT_DATE → const String
CHANNEL_METHOD_GET_PLATFORM_VERSION → const String
CHANNEL_METHOD_GET_UTC_TIMEZONE_IDENTIFIER → const String
CHANNEL_METHOD_INCREMENT_BADGE_COUNT → const String
CHANNEL_METHOD_INITIALIZE → const String
CHANNEL_METHOD_IS_FCM_AVAILABLE → const String
CHANNEL_METHOD_IS_NOTIFICATION_ACTIVE → const String
CHANNEL_METHOD_IS_NOTIFICATION_ALLOWED → const String
CHANNEL_METHOD_ISOLATE_SHUTDOWN → const String
CHANNEL_METHOD_LIST_ALL_SCHEDULES → const String
CHANNEL_METHOD_NEW_FCM_TOKEN → const String
CHANNEL_METHOD_NOTIFICATION_AT_LAUNCH → const String
CHANNEL_METHOD_PUSH_NEXT_DATA → const String
CHANNEL_METHOD_REMOVE_NOTIFICATION_CHANNEL → const String
CHANNEL_METHOD_REQUEST_NOTIFICATIONS → const String
CHANNEL_METHOD_RESET_BADGE → const String
CHANNEL_METHOD_SET_BADGE_COUNT → const String
CHANNEL_METHOD_SET_EVENT_HANDLES → const String
CHANNEL_METHOD_SET_LOCALIZATION → const String
CHANNEL_METHOD_SET_NOTIFICATION_CHANNEL → const String
CHANNEL_METHOD_SHOULD_SHOW_RATIONALE → const String
CHANNEL_METHOD_SHOW_ALARM_PAGE → const String
CHANNEL_METHOD_SHOW_GLOBAL_DND_PAGE → const String
CHANNEL_METHOD_SHOW_NOTIFICATION_PAGE → const String
CHANNEL_METHOD_SILENT_CALLBACK → const String
CHANNEL_METHOD_START_FOREGROUND → const String
CHANNEL_METHOD_STOP_FOREGROUND → const String
CREATED_HANDLE → const String
DART_REVERSE_CHANNEL → const String
DATE_FORMAT → const String
DEC → const String
DEFAULT_ICON → const String
DISMISSED_HANDLE → const String
DISPLAYED_HANDLE → const String
DRAWABLE_RESOURCE_REFERENCE → const String
EVENT_DEFAULT_ACTION → const String
EVENT_NOTIFICATION_CREATED → const String
EVENT_NOTIFICATION_DISMISSED → const String
EVENT_NOTIFICATION_DISPLAYED → const String
EVENT_SILENT_ACTION → const String
EXTRA_BROADCAST_FCM_TOKEN → const String
EXTRA_BROADCAST_MESSAGE → const String
FEB → const String
FOREGROUND_NOTIFICATION_MODEL → const String
FOREGROUND_SERVICE_TYPE → const String
FOREGROUND_START_MODE → const String
FRI → const String
INITIALIZE_CHANNELS → const String
INITIALIZE_CHANNELS_GROUPS → const String
INITIALIZE_CLEAR_STORED_ACTIONS → const String
INITIALIZE_DEBUG_MODE → const String
INITIALIZE_DEFAULT_ICON → const String
INVALID_BIG_PICTURE_ERROR_CODE → const String
INVALID_DRAWABLE_RESOURCE_ERROR_MESSAGE → const String
INVALID_ICON_ERROR_CODE → const String
INVALID_LARGE_ICON_ERROR_CODE → const String
INVALID_LED_DETAILS_ERROR_CODE → const String
INVALID_LED_DETAILS_ERROR_MESSAGE → const String
INVALID_RAW_RESOURCE_ERROR_MESSAGE → const String
INVALID_SOUND_ERROR_CODE → const String
JAN → const String
JUL → const String
JUN → const String
MAR → const String
MAY → const String
MON → const String
NOTIFICATION_ACTION_BUTTONS → const String
NOTIFICATION_ACTION_DATE → const String
NOTIFICATION_ACTION_LIFECYCLE → const String
NOTIFICATION_ACTION_TYPE → const String
NOTIFICATION_ALLOW_WHILE_IDLE → const String
NOTIFICATION_AUTHENTICATION_REQUIRED → const String
NOTIFICATION_AUTO_DISMISSIBLE → const String
NOTIFICATION_BACKGROUND_COLOR → const String
NOTIFICATION_BADGE → const String
NOTIFICATION_BIG_PICTURE → const String
NOTIFICATION_BODY → const String
NOTIFICATION_BODY_ARGS → const String
NOTIFICATION_BODY_KEY → const String
NOTIFICATION_BOT → const String
NOTIFICATION_BUTTON_ACTION_PREFIX → const String
NOTIFICATION_BUTTON_INPUT → const String
NOTIFICATION_BUTTON_KEY → const String
NOTIFICATION_BUTTON_KEY_INPUT → const String
NOTIFICATION_BUTTON_KEY_PRESSED → const String
NOTIFICATION_BUTTON_LABEL → const String
NOTIFICATION_BUTTON_LABELS → const String
NOTIFICATION_BUTTONS → const String
NOTIFICATION_CATEGORY → const String
NOTIFICATION_CHANNEL_ACTION → const String
NOTIFICATION_CHANNEL_CRITICAL_ALERTS → const String
NOTIFICATION_CHANNEL_DESCRIPTION → const String
NOTIFICATION_CHANNEL_GROUP_KEY → const String
NOTIFICATION_CHANNEL_GROUP_NAME → const String
NOTIFICATION_CHANNEL_KEY → const String
NOTIFICATION_CHANNEL_NAME → const String
NOTIFICATION_CHANNEL_SHOW_BADGE → const String
NOTIFICATION_CHRONOMETER → const String
NOTIFICATION_COLOR → const String
NOTIFICATION_CONTENT → const String
NOTIFICATION_CONVERSATION_TITLE → const String
NOTIFICATION_CREATED_DATE → const String
NOTIFICATION_CREATED_LIFECYCLE → const String
NOTIFICATION_CREATED_SOURCE → const String
NOTIFICATION_CRITICAL_ALERT → const String
NOTIFICATION_CRONTAB_EXPRESSION → const String
NOTIFICATION_CUSTOM_SOUND → const String
NOTIFICATION_DATA_MIME_TYPE → const String
NOTIFICATION_DATA_URI → const String
NOTIFICATION_DEFAULT_COLOR → const String
NOTIFICATION_DEFAULT_PRIVACY → const String
NOTIFICATION_DEFAULT_RINGTONE_TYPE → const String
NOTIFICATION_DISMISSED_DATE → const String
NOTIFICATION_DISMISSED_LIFE_CYCLE → const String
NOTIFICATION_DISPLAY_ON_BACKGROUND → const String
NOTIFICATION_DISPLAY_ON_FOREGROUND → const String
NOTIFICATION_DISPLAYED_DATE → const String
NOTIFICATION_DISPLAYED_LIFECYCLE → const String
NOTIFICATION_DURATION → const String
NOTIFICATION_ENABLE_LIGHTS → const String
NOTIFICATION_ENABLE_VIBRATION → const String
NOTIFICATION_ENABLED → const String
NOTIFICATION_EXPANDABLE_BODY → const String
NOTIFICATION_EXPIRATION_DATE_TIME → const String
NOTIFICATION_FULL_SCREEN_INTENT → const String
NOTIFICATION_GROUP_ALERT_BEHAVIOR → const String
NOTIFICATION_GROUP_CONVERSATION → const String
NOTIFICATION_GROUP_KEY → const String
NOTIFICATION_GROUP_SORT → const String
NOTIFICATION_HIDE_LARGE_ICON_ON_EXPAND → const String
NOTIFICATION_ICON → const String
NOTIFICATION_ICON_RESOURCE_ID → const String
NOTIFICATION_ID → const String
NOTIFICATION_IMPORTANCE → const String
NOTIFICATION_IMPORTANT → const String
NOTIFICATION_INDETERMINATE → const String
NOTIFICATION_INITIAL_DATE_TIME → const String
NOTIFICATION_INITIAL_FIXED_DATE → const String
NOTIFICATION_IS_DANGEROUS_OPTION → const String
NOTIFICATION_JSON → const String
NOTIFICATION_KEY → const String
NOTIFICATION_LARGE_ICON → const String
NOTIFICATION_LAYOUT → const String
NOTIFICATION_LED_COLOR → const String
NOTIFICATION_LED_OFF_MS → const String
NOTIFICATION_LED_ON_MS → const String
NOTIFICATION_LOCALIZATIONS → const String
NOTIFICATION_LOCKED → const String
NOTIFICATION_MAX_PROGRESS → const String
NOTIFICATION_MESSAGES → const String
NOTIFICATION_NAME → const String
NOTIFICATION_ONLY_ALERT_ONCE → const String
NOTIFICATION_PAYLOAD → const String
NOTIFICATION_PERMISSIONS → const String
NOTIFICATION_PERSON → const String
NOTIFICATION_PLATFORM_CONFIGURATION → const String
NOTIFICATION_PLAY_SOUND → const String
NOTIFICATION_PLAY_STATE → const String
NOTIFICATION_PLAYBACK_SPEED → const String
NOTIFICATION_PRECISE_SCHEDULES → const String
NOTIFICATION_PRIVACY → const String
NOTIFICATION_PRIVATE_MESSAGE → const String
NOTIFICATION_PROGRESS → const String
NOTIFICATION_REQUIRE_INPUT_TEXT → const String
NOTIFICATION_ROUNDED_BIG_PICTURE → const String
NOTIFICATION_ROUNDED_LARGE_ICON → const String
NOTIFICATION_SCHEDULE → const String
NOTIFICATION_SCHEDULE_ALLOW_WHILE_IDLE → const String
NOTIFICATION_SCHEDULE_DAY → const String
NOTIFICATION_SCHEDULE_DELAY_TOLERANCE → const String
NOTIFICATION_SCHEDULE_ERA → const String
NOTIFICATION_SCHEDULE_HOUR → const String
NOTIFICATION_SCHEDULE_INTERVAL → const String
NOTIFICATION_SCHEDULE_MILLISECOND → const String
NOTIFICATION_SCHEDULE_MINUTE → const String
NOTIFICATION_SCHEDULE_MONTH → const String
NOTIFICATION_SCHEDULE_PRECISE_ALARM → const String
NOTIFICATION_SCHEDULE_REPEATS → const String
NOTIFICATION_SCHEDULE_SECOND → const String
NOTIFICATION_SCHEDULE_TIMEZONE → const String
NOTIFICATION_SCHEDULE_WEEKDAY → const String
NOTIFICATION_SCHEDULE_WEEKOFMONTH → const String
NOTIFICATION_SCHEDULE_WEEKOFYEAR → const String
NOTIFICATION_SCHEDULE_YEAR → const String
NOTIFICATION_SHOW_IN_COMPACT_VIEW → const String
NOTIFICATION_SHOW_PROGRESS → const String
NOTIFICATION_SHOW_WHEN → const String
NOTIFICATION_SOUND_SOURCE → const String
NOTIFICATION_SUMMARY → const String
NOTIFICATION_SYSTEM_ID → const String
NOTIFICATION_TEXT → const String
NOTIFICATION_TICKER → const String
NOTIFICATION_TIMEOUT_AFTER → const String
NOTIFICATION_TIMESTAMP → const String
NOTIFICATION_TITLE → const String
NOTIFICATION_TITLE_ARGS → const String
NOTIFICATION_TITLE_KEY → const String
NOTIFICATION_URI → const String
NOTIFICATION_VIBRATION_PATTERN → const String
NOTIFICATION_WAKE_UP_SCREEN → const String
NOV → const String
OCT → const String
PUSH_SOURCE_FIREBASE → const String
PUSH_SOURCE_LOCAL_NOTIFICATION → const String
PUSH_SOURCE_ONE_SIGNAL → const String
RECOVER_DISPLAYED → const String
RGBA32HeaderSize → const int
SAT → const String
SCHEDULED_NOTIFICATIONS → const String
SELECT_NOTIFICATION → const String
SEP → const String
SHARED_PREFERENCES_KEY → const String
SUN → const String
THU → const String
TUE → const String
WED → const String

Properties

highVibrationPattern Int64List
getter/setter pair
lowVibrationPattern Int64List
getter/setter pair
mediumVibrationPattern Int64List
getter/setter pair

Typedefs

ActionHandler = Future<void> Function(ReceivedAction receivedAction)
Method structure to listen to an incoming action with dart
NotificationHandler = Future<void> Function(ReceivedNotification receivedNotification)
Method structure to listen to an notification event with dart