ControlledComponentData<T> class

Immutable data container for controlled component state.

This class encapsulates the three essential pieces of state that controlled components need: the current value, a change callback, and the enabled status. It provides a convenient way to pass this state to widget builders.

The generic type T represents the type of value being managed.

Constructors

ControlledComponentData.new({required T value, required ValueChanged<T> onChanged, required bool enabled})
Creates a ControlledComponentData with the specified state.
const

Properties

enabled bool
Whether the component should accept user input.
final
hashCode int
The hash code for this object.
no setterinherited
onChanged ValueChanged<T>
Callback to invoke when the value should change.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
value → T
The current value of the component.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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