Interface TxAction<T>

  • Type Parameters:
    T - return type
    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 TxAction<T>
    Transaction action passed to transaction template.
    Since:
    31.08.2018
    See Also:
    for usage
    • Method Detail

      • execute

        T execute​(org.jdbi.v3.core.Handle handle)
           throws java.lang.Exception
        Called under transaction. Exceptions are propagated and cause transaction rollback.
        Parameters:
        handle - current JDBI handle under unit of work
        Returns:
        action result
        Throws:
        java.lang.Exception - on errors (used to move exceptions handling outside of action)