FValueListenable<T> class abstract

An interface for subclasses of Listenable that expose a value.

This interface is implemented by ValueNotifier<T> and Animation<T>, and allows other APIs to accept either of those implementations interchangeably.

See also:

  • ValueListenableBuilder, a widget that uses a builder callback to rebuild whenever a ValueListenable object triggers its notifications, providing the builder with the value of the object.
Inheritance
Implementers

Constructors

FValueListenable()
Abstract const constructor. This constructor enables subclasses to provide const constructors so that they can be used in const expressions.
const

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value → T
The current value of the object. When the value changes, the callbacks registered with addListener will be invoked.
no setter

Methods

addListener(VoidCallback listener) → void
Return a Listenable that triggers when any of the given Listenables themselves trigger.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that the object notifies.
inherited
toString() String
A string representation of this object.
inherited

Operators

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