match
R
match<
Pattern match on nullable value with cases for non-null and null.
Implementation
R match<R>({required R Function(T) some, required R Function() none}) =>
switch (this) {
final T value => some(value),
null => none(),
};