getters method

  1. @override
Map<String, Function> getters()
override

mark these functions as protected as we need the implementations, but discourage direct usages. Reasons:

  1. There are more base getters/setters/methods from the base class. Users can just focus on defining only applicable fields for their classes but still get the base implementations automatically.
  2. setProperty() will automatically notify the controller's listeners for changes, enabling the listeners (widget state) to redraw.

Use getProperty/setProperty/callMethod instead of these.

Implementation

@override
Map<String, Function> getters() {
  return {};
}