Interface ThrowingFunction<T,R,E extends Throwable>

Type Parameters:
T - the type of argument consumed by this function
R - the type of results returned by this function
E - the type of Throwable that may be thrown by this function
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ThrowingFunction<T,R,E extends Throwable>
Represents a function that may throw and accepts one argument and produces a result.

Like Function but able to throw an exception

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    apply(T t)
    Applies this function to the given argument.
  • Method Details

    • apply

      R apply(T t) throws E
      Applies this function to the given argument.
      Parameters:
      t - the function argument
      Returns:
      the function result
      Throws:
      E - Throwable that may be thrown
      See Also: