Interface ThrowingFunction<R,T,E extends Exception>

Type Parameters:
R - type of result
T - type of input
E - type of exception

public interface ThrowingFunction<R,T,E extends Exception>
Represents a function which can throw an exception.

this is usefull when you need to delegate checked exceptions

  • Method Summary

    Modifier and Type
    Method
    Description
    apply(T t)
    A function which maps a value to another value and can throw an exception
  • Method Details

    • apply

      R apply(T t) throws E
      A function which maps a value to another value and can throw an exception
      Parameters:
      t - input
      Returns:
      value
      Throws:
      E - if something went wrong