Enables control over a single ExpansionTile's expanded/collapsed state.
It can be useful to expand or collapse an ExpansionTile programatically, for example to reconfigure an existing expansion tile based on a system event. To do so, create an ExpansionTile with an ExpansionTileController that's owned by a stateful widget or look up the tile's automatically created ExpansionTileController with ExpansionTileController.of
The controller's expand and collapse methods cause the the ExpansionTile to rebuild, so they may not be called from a build method.
- Create a controller to be used with ExpansionTile.controller.
- hashCode → int
The hash code for this object.
- isExpanded → bool
Whether the ExpansionTile built with this controller is in expanded state.
- runtimeType → Type
A representation of the runtime type of the object.
) → void
- Collapses the ExpansionTile that was built with this controller.
) → void
- Expands the ExpansionTile that was built with this controller;
Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
) → String
A string representation of this object.
Object other) → bool
The equality operator.
BuildContext context) → ExpansionTileController?
- Finds the ExpansionTile from the closest instance of this class that encloses the given context and returns its ExpansionTileController.
BuildContext context) → ExpansionTileController
- Finds the ExpansionTileController for the closest ExpansionTile instance that encloses the given context.