public final class SqlStatements extends Object implements JdbiConfig<SqlStatements>
| Constructor and Description |
|---|
SqlStatements() |
| Modifier and Type | Method and Description |
|---|---|
SqlStatements |
createCopy()
Returns a copy of this configuration object.
|
SqlStatements |
define(String key,
Object value)
Define an attribute for
StatementContext for statements executed by JDBI. |
SqlStatements |
defineMap(Map<String,?> values)
Defines attributes for each key/value pair in the Map.
|
Object |
getAttribute(String key)
Obtain the value of an attribute
|
Map<String,Object> |
getAttributes()
Returns the attributes which will be applied to
SQL statements created by JDBI. |
StatementRewriter |
getStatementRewriter() |
TimingCollector |
getTimingCollector() |
SqlStatements |
setStatementRewriter(StatementRewriter rewriter)
Sets the
StatementRewriter used to transform SQL for all SQL satements executed by
JDBI. |
SqlStatements |
setTimingCollector(TimingCollector timingCollector)
Sets the
TimingCollector used to collect timing about the SQL statements executed
by JDBI. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsetRegistrypublic SqlStatements createCopy()
JdbiConfigcreateCopy in interface JdbiConfig<SqlStatements>public SqlStatements define(String key, Object value)
StatementContext for statements executed by JDBI.key - the key for the attributevalue - the value for the attributepublic SqlStatements defineMap(Map<String,?> values)
values - map of attributes to define.public Object getAttribute(String key)
key - the name of the attributepublic Map<String,Object> getAttributes()
SQL statements created by JDBI.public StatementRewriter getStatementRewriter()
public TimingCollector getTimingCollector()
public SqlStatements setStatementRewriter(StatementRewriter rewriter)
StatementRewriter used to transform SQL for all SQL satements executed by
JDBI. The default statement rewriter handles named parameter interpolation.rewriter - the new statement rewriter.public SqlStatements setTimingCollector(TimingCollector timingCollector)
TimingCollector used to collect timing about the SQL statements executed
by JDBI. The default collector does nothing.timingCollector - the new timing collectorCopyright © 2017. All rights reserved.