QueryResultBuilder<T>.sync constructor

QueryResultBuilder<T>.sync({
  1. Key? key,
  2. required QueryResult<T> result,
  3. Widget? child,
  4. required ValueWidgetBuilder<Object> failedBuilder,
  5. required ValueWidgetBuilder<T> succeededBuilder,
})

Consume ActionResult

Implementation

QueryResultBuilder.sync({
  Key? key,
  required QueryResult<T> result,
  Widget? child,
  required ValueWidgetBuilder<Object> failedBuilder,
  required ValueWidgetBuilder<T> succeededBuilder,
}) : super(
        key: key,
        stated: result,
        child: child,
        patternDefs: (b) => b
          ..error(OnState.isFailed(), failedBuilder)
          ..value(OnState.isSuceeded(), succeededBuilder),
      );