public static <T, R, E extends Exception> Function<T, R> rethrowFunction(
            FunctionWithExceptions<T, R, E> function)
            throws E {
        return t -> {
            try {
                return function.apply(t);
            } catch (Exception exception) {
                throwAsUnchecked(exception);
                return null;
            }
        };
    }
e.g:
.map(rethrowFunction(name -> Class.forName(name)))
or
.map(rethrowFunction(Class::forName))
stroom-util/src/main/java/stroom/util/exception/LambdaExceptionUtil.java