Interface ExtensionCallback<R,​E,​X extends java.lang.Exception>

  • Type Parameters:
    R - return type
    E - extension type
    X - optional exception type thrown by the callback
    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 ExtensionCallback<R,​E,​X extends java.lang.Exception>
    • Method Detail

      • withExtension

        R withExtension​(E extension)
                 throws X extends java.lang.Exception
        Will be invoked with a live extension. The associated handle will be closed when this callback returns.
        Parameters:
        extension - extension to be used only within the scope of this callback.
        Returns:
        the return value of the callback
        Throws:
        X - optional exception thrown by this callback.
        X extends java.lang.Exception