Toaster class abstract

Constructors

Toaster.new()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
toasts List<Toast>
view all the toasts; usually you won't use this method, but it might be useful if you're attempting to see if a toast was already inserted:
no setter

Methods

add(Toast toast) → void
add a toast.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
remove(String toastId) → void
manually removes a toast with toastId from the toasts. will not trigger the toasts toastsAction, but will trigger the toasts dismissAction.
toString() String
A string representation of this object.
inherited

Operators

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

Static Methods

mount({Key? key, required Widget child, ToastBuilder? toastBuilder}) Widget
mount the Toaster in the widget tree for reference later. Toaster uses an InheritedWidget, so all rules apply; a Toaster may be shadowed by a new Toaster, and the BuildContext used to refrence the Toaster must be in the same tree as the Toaster.
of(BuildContext context) Toaster
refrence the nearest Toaster.