refresh method

  1. @override
void refresh()
override

Allows the user to call setState() within the Controller.

Implementation

@override
void refresh() {
  // Critical to have the App 'refresh' first.
  // It uses a built-in InheritedWidget.
  App.refresh();
  if (mounted) {
    // Next refresh the current State object itself.
    super.refresh();
  }
}