flatMap<R> method

R? flatMap<R>(
  1. R f(
    1. T
    )
)

returns some value if both this and returned value of function f are some.

Implementation

R? flatMap<R>(R Function(T) f) {
  if (this == null) {
    return null;
  }
  return f(this!);
}