onInvalidated static method

Stream<void> onInvalidated(
  1. List key
)

Returns a broadcast Stream that emits whenever queries matching key are invalidated.

Subscribed to by BloomQuery to trigger background re-fetching.

Implementation

static Stream<void> onInvalidated(List<dynamic> key) {
  final keyStr = normalizeKey(key);
  return _invalidationControllers
      .putIfAbsent(keyStr, () => StreamController<void>.broadcast())
      .stream;
}