ValueListenable<T> class

An interface for subclasses of Listenable that expose a value.

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

Inheritance
Implemented by

Constructors

ValueListenable()

Properties

value → T
The current value of the object. When the value changes, the callbacks registered with addListener will be invoked.
read-only
hashCode int
The hash code for this object. [...]
read-only, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object notifies its listeners.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
@pragma('vm:entry-point'), inherited
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that the object notifies.
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

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