mapNotNull<R> method
Returns a new lazy Iterable containing only the non-null results of
applying the given transform
function to each element in the original
collection.
Implementation
Iterable<R> mapNotNull<R>(R? Function(E element) transform) sync* {
for (final element in this) {
final result = transform(element);
if (result != null) {
yield result;
}
}
}