Class TransactionalHandleSupplier

java.lang.Object
org.jdbi.v3.core.TransactionalHandleSupplier
All Implemented Interfaces:
AutoCloseable, org.jdbi.v3.core.extension.HandleSupplier

@Singleton public class TransactionalHandleSupplier extends Object implements org.jdbi.v3.core.extension.HandleSupplier
Bridge have to lie in jdbi package in order have access to internal methods. Implementation is the same as in ConstantHandleSupplier, except handler and config are obtained dynamically.
Since:
31.08.2018
  • Constructor Summary

    Constructors
    Constructor
    Description
    TransactionalHandleSupplier(org.jdbi.v3.core.Jdbi jdbi, jakarta.inject.Provider<org.jdbi.v3.core.Handle> handleProvider)
    Create a transactional handle supplier.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.jdbi.v3.core.config.ConfigRegistry
     
    org.jdbi.v3.core.Handle
     
    org.jdbi.v3.core.Jdbi
     
    <V> V
    invokeInContext(org.jdbi.v3.core.extension.ExtensionContext extensionContext, Callable<V> task)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.jdbi.v3.core.extension.HandleSupplier

    close
  • Constructor Details

    • TransactionalHandleSupplier

      @Inject public TransactionalHandleSupplier(org.jdbi.v3.core.Jdbi jdbi, jakarta.inject.Provider<org.jdbi.v3.core.Handle> handleProvider)
      Create a transactional handle supplier.
      Parameters:
      jdbi - jdbi instance
      handleProvider - handle provider
  • Method Details

    • getHandle

      public org.jdbi.v3.core.Handle getHandle()
      Specified by:
      getHandle in interface org.jdbi.v3.core.extension.HandleSupplier
    • getJdbi

      public org.jdbi.v3.core.Jdbi getJdbi()
      Specified by:
      getJdbi in interface org.jdbi.v3.core.extension.HandleSupplier
    • invokeInContext

      public <V> V invokeInContext(org.jdbi.v3.core.extension.ExtensionContext extensionContext, Callable<V> task) throws Exception
      Specified by:
      invokeInContext in interface org.jdbi.v3.core.extension.HandleSupplier
      Throws:
      Exception
    • getConfig

      public org.jdbi.v3.core.config.ConfigRegistry getConfig()
      Specified by:
      getConfig in interface org.jdbi.v3.core.extension.HandleSupplier