replaceDefaultScheduler function
Replaces the default scheduler instance to be used.
Implementation
Disposable replaceDefaultScheduler(Scheduler? scheduler) {
final originalScheduler = _defaultScheduler;
_defaultScheduler = scheduler;
return ActionDisposable(() => _defaultScheduler = originalScheduler);
}