addRx method

  1. @protected
void addRx(
  1. Rx rx
)

Add an Rx to this composite

Implementation

@protected
void addRx(Rx rx) {
  if (_subs[identityHashCode(rx)] != null) return;

  // Pana was complaining about this for no reason
  // ignore: cancel_subscriptions
  final sub = rx.stream.listen((_) => notify());
  _subs[identityHashCode(rx)] = sub;
}