Notification class

Inheritance
Annotations
  • @Native("Notification")

Constructors

Notification(String title, {String? dir, String? body, String? lang, String? tag, String? icon})
factory

Properties

actionsList?
read-only
badgeString?
read-only
bodyString?
read-only
dataObject?
@annotation_Creates_SerializedScriptValue, @annotation_Returns_SerializedScriptValue, read-only
dirString?
read-only
hashCodeint
read-only, inherited
The hash code for this object. [...]
iconString?
read-only
imageString?
read-only
langString?
read-only
onEvents
read-only, inherited
This is an ease-of-use accessor for event streams which should only be used when an explicit accessor is not available.
onClickStream<Event>
read-only
Stream of click events handled by this Notification.
onCloseStream<Event>
read-only
Stream of close events handled by this Notification.
onErrorStream<Event>
read-only
Stream of error events handled by this Notification.
onShowStream<Event>
read-only
Stream of show events handled by this Notification.
renotifybool?
read-only
requireInteractionbool?
read-only
runtimeTypeType
read-only, inherited
A representation of the runtime type of the object.
silentbool?
read-only
tagString?
read-only
timestampint?
read-only
titleString?
read-only
vibrateList<int>?
read-only

Methods

addEventListener(String type, EventListener? listener, [bool? useCapture]) → void
inherited
close() → void
dispatchEvent(Event event) → bool
inherited
noSuchMethod(Invocation invocation) → dynamic
inherited
Invoked when a non-existent method or property is accessed. [...]
removeEventListener(String type, EventListener? listener, [bool? useCapture]) → void
inherited
toString() → String
inherited
A string representation of this object. [...]

Operators

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

Static Properties

maxActionsint?
read-only
permissionString?
read-only
supportedbool
read-only
Checks if this type is supported on the current platform.

Static Methods

requestPermission() → Future<String>
@JSName('requestPermission')

Constants

clickEvent → const EventStreamProvider<Event>
Static factory designed to expose click events to event handlers that are not necessarily instances of Notification. [...]
const EventStreamProvider<Event>('click')
closeEvent → const EventStreamProvider<Event>
Static factory designed to expose close events to event handlers that are not necessarily instances of Notification. [...]
const EventStreamProvider<Event>('close')
errorEvent → const EventStreamProvider<Event>
Static factory designed to expose error events to event handlers that are not necessarily instances of Notification. [...]
const EventStreamProvider<Event>('error')
showEvent → const EventStreamProvider<Event>
Static factory designed to expose show events to event handlers that are not necessarily instances of Notification. [...]
const EventStreamProvider<Event>('show')

© 2012 the Dart project authors
Licensed under the Creative Commons Attribution-ShareAlike License v4.0.
https://api.dart.dev/stable/2.13.0/dart-html/Notification-class.html