/** * Returns a Function which wraps {@code function} and rethrows any exceptions as unchecked exceptions. * <p> * If you are getting an error about {@code the method wrap is ambiguous}, use * {@link #wrapFunction(com.diffplug.common.base.Throwing.Function)} or * {@link #wrapPredicate(com.diffplug.common.base.Throwing.Predicate). * */ public <T, R> Function<T, R> wrap(Throwing.Function<T, R> function) { return wrapFunction(function); }
/** * Returns a Function which wraps {@code function} and rethrows any exceptions as unchecked exceptions. * <p> * If you are getting an error about {@code the method wrap is ambiguous}, use * {@link #wrapFunction(com.diffplug.common.base.Throwing.Function)} or * {@link #wrapPredicate(com.diffplug.common.base.Throwing.Predicate). * */ public <T, R> Function<T, R> wrap(Throwing.Function<T, R> function) { return wrapFunction(function); }
/** * Returns a Function which wraps {@code function} and rethrows any exceptions as unchecked exceptions. * <p> * If you are getting an error about {@code the method wrap is ambiguous}, use * {@link #wrapFunction(com.diffplug.common.base.Throwing.Function)} or * {@link #wrapPredicate(com.diffplug.common.base.Throwing.Predicate). * */ public <T, R> Function<T, R> wrap(Throwing.Function<T, R> function) { return wrapFunction(function); }