current property

Disposable get current

Implementation

Disposable get current => _current;
set current (Disposable disposable)

Implementation

set current(Disposable disposable) {
  if (isDisposed) {
    disposable.dispose();
    return;
  }
  final previous = _current;
  if (disposable.isDisposed) {
    _current = const DisposedDisposable();
  } else {
    _current = disposable;
  }
  previous.dispose();
}