smartAddAll method

void smartAddAll(
  1. Iterable<T> values
)

Adds all elements from the given values to the set and notifies listeners if the set changed.

  • values: The elements to add to the set.

Implementation

void smartAddAll(Iterable<T> values) {
  final oldLength = length;
  value.addAll(values);
  if (oldLength != length) {
    notify();
  }
}