runZoned<R> static method
- @Deprecated('This will be removed in v9.0.0. Use Bloc.observer/Bloc.transformer instead.')
- R body(), {
- BlocObserver? blocObserver,
- EventTransformer? eventTransformer,
Runs body
in a fresh Zone using the provided overrides.
Implementation
@Deprecated(
'This will be removed in v9.0.0. Use Bloc.observer/Bloc.transformer instead.',
)
static R runZoned<R>(
R Function() body, {
BlocObserver? blocObserver,
EventTransformer<dynamic>? eventTransformer,
}) {
final overrides = _BlocOverridesScope(blocObserver, eventTransformer);
return _asyncRunZoned(body, zoneValues: {_token: overrides});
}