Try<R, Failure> flatMap<R>( Try<R, Failure> Function(Success value) transform) { if (isSuccess) { return transform(getOrThrow()); } else { return Try.failure(exceptionOrNull()); } }