Package org.jdbi.v3.core.statement
Interface StatementContextListener
Listener interface for the
StatementContext
. Each method will be called when specific events with the context happen.-
Method Summary
Modifier and TypeMethodDescriptiondefault void
cleanableAdded
(StatementContext statementContext, Cleanable cleanable) ACleanable
object was added to this context for cleanup when the context is cleaned.default void
cleanableRemoved
(StatementContext statementContext, Cleanable cleanable) ACleanable
object was removed from the context.default void
contextCleaned
(StatementContext statementContext) AStatementContext
object was cleaned.default void
contextCreated
(StatementContext statementContext) A newStatementContext
is created.
-
Method Details
-
contextCreated
A newStatementContext
is created.- Parameters:
statementContext
- TheStatementContext
object that was created. Never null.
-
contextCleaned
AStatementContext
object was cleaned. Implementers should be aware that theStatementContext.close()
method can be called multiple times as Statements can be reused.- Parameters:
statementContext
- TheStatementContext
object that was cleaned. Never null.
-
cleanableAdded
ACleanable
object was added to this context for cleanup when the context is cleaned.- Parameters:
statementContext
- TheStatementContext
. Never null.cleanable
- TheCleanable
object that should be closed when the context is closed. Never null.
-
cleanableRemoved
ACleanable
object was removed from the context.- Parameters:
statementContext
- TheStatementContext
. Never null.cleanable
- TheCleanable
object that was removed from the context.
-