DropdownMenuItem<T> class
A data model for a single option in a DropdownButton.
Each item has a value of type T, a display label, and an enabled flag.
Constructors
- DropdownMenuItem({required T value, required String label, bool enabled = true})
-
Creates a DropdownMenuItem with the given
valueandlabel.const
Properties
- enabled → bool
-
Whether this item can be selected.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- label → String
-
The text displayed for this item.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- value → T
-
The value represented by this menu item.
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