builder method

BlocBuilder<BlocBase, dynamic> builder(
  1. Widget builder(
    1. BuildContext,
    2. TakeState
    ), {
  2. bool buildWhen(
    1. TakeState,
    2. TakeState
    )?,
})

Implementation

BlocBuilder builder(Widget Function(BuildContext, TakeState) builder,
    {bool Function(TakeState, TakeState)? buildWhen}) {
  return BlocBuilder<TakeBloc, TakeState>(
    bloc: _takeBloc,
    builder: (BuildContext context, TakeState takeState) {
      return builder(context, takeState);
    },
    buildWhen: (TakeState beforeTakeState, TakeState afterTakeState) {
      return buildWhen == null
          ? true
          : buildWhen(beforeTakeState, afterTakeState);
    },
  );
}