Package org.jdbi.v3.core
Class ConstantHandleSupplier
java.lang.Object
org.jdbi.v3.core.AbstractHandleSupplier
org.jdbi.v3.core.ConstantHandleSupplier
- All Implemented Interfaces:
AutoCloseable,HandleSupplier
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the current Jdbi config.Returns a handle, possibly creating it lazily.getJdbi()Returns the owning Jdbi instance.(package private) static HandleSupplierprotected voidwithHandle(Consumer<Handle> handleConsumer) Methods inherited from class org.jdbi.v3.core.AbstractHandleSupplier
close, currentExtensionContext, invokeInContext
-
Field Details
-
handle
-
-
Constructor Details
-
ConstantHandleSupplier
ConstantHandleSupplier(Handle handle)
-
-
Method Details
-
of
-
getJdbi
Description copied from interface:HandleSupplierReturns the owning Jdbi instance.- Returns:
- The owning Jdbi instance.
-
getConfig
Description copied from interface:HandleSupplierReturns the current Jdbi config.- Returns:
- The current Jdbi configuration.
-
getHandle
Description copied from interface:HandleSupplierReturns a handle, possibly creating it lazily. A Handle holds a database connection, so extensions should only call this method in order to interact with the database.- Returns:
- An open Handle.
-
withHandle
- Specified by:
withHandlein classAbstractHandleSupplier
-