observe<T extends Model> method

Stream<SubscriptionEvent<T>> observe<T extends Model>(
  1. ModelType<T> modelType, {
  2. QueryPredicate<Model>? where,
})

Observe changes on the specified modelType.

Implementation

Stream<SubscriptionEvent<T>> observe<T extends Model>(
  ModelType<T> modelType, {
  QueryPredicate? where,
}) {
  return plugins.length == 1
      ? plugins[0].observe(modelType, where: where)
      : throw _pluginNotAddedException('DataStore');
}