union method
- Set<
E> other
override
Returns a new set which contains all the elements of this
and other
.
That is, the returned set contains all the elements of this Set and all
the elements of other
.
Note that the returned set will use the default equality operation, which
may be different than the equality operation this
uses.
Implementation
@override
Set<E> union(Set<E> other) => toSet()..addAll(other);