WidgetModelBuilder<TEvent extends BaseEvent, TModel extends IObservable<TEvent>> constructor

WidgetModelBuilder<TEvent extends BaseEvent, TModel extends IObservable<TEvent>>({
  1. required TModel model,
  2. required TEvent? initialEvent,
  3. required Widget builder(
    1. BuildContext context,
    2. TModel model,
    3. TEvent? previousEvent,
    4. TEvent? event,
    ),
  4. bool buildWhen(
    1. TModel model,
    2. TEvent? previous,
    3. TEvent? current
    )?,
  5. void listener(
    1. TEvent? previous,
    2. TEvent? current
    )?,
})

Implementation

WidgetModelBuilder(
    {required TModel model,
    required this.initialEvent,
    required Widget Function(BuildContext context, TModel model,
            TEvent? previousEvent, TEvent? event)
        builder,
    bool Function(TModel model, TEvent? previous, TEvent? current)? buildWhen,
    void Function(TEvent? previous, TEvent? current)? listener})
    : super(
          model: model,
          buildWhen: buildWhen,
          builder: builder,
          listener: listener);