- java.lang.Object
-
- org.jooq.tools.jdbc.MockConfiguration
-
- All Implemented Interfaces:
Serializable
,Configuration
public class MockConfiguration extends Object implements Configuration
A mock configuration.This
Configuration
wraps a delegateConfiguration
and wraps allConnectionProvider
references inMockConnectionProvider
.- Author:
- Lukas Eder
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MockConfiguration(Configuration delegate, MockDataProvider provider)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Clock
clock()
Get this configuration'sClock
, which is used for optimistic locking, transaction time, and other time-depending features.ConnectionProvider
connectionProvider()
Get this configuration's underlying connection provider.ConverterProvider
converterProvider()
Get the configuredConverterProvider
from this configuration.Map<Object,Object>
data()
Get all custom data from thisConfiguration
.Object
data(Object key)
Get some custom data from thisConfiguration
.Object
data(Object key, Object value)
Set some custom data to thisConfiguration
.Configuration
derive()
Create a derived configuration from this one, without changing any properties.Configuration
derive(Connection newConnection)
Create a derived configuration from this one, with a new connection wrapped in aDefaultConnectionProvider
.Configuration
derive(Clock newClock)
Create a derived configuration from this one, with a newClock
.Configuration
derive(Executor newExecutor)
Create a derived configuration from this one, with a new executor.Configuration
derive(DataSource newDataSource)
Create a derived configuration from this one, with a new data source wrapped in aDataSourceConnectionProvider
.Configuration
derive(Settings newSettings)
Create a derived configuration from this one, with new settings.Configuration
derive(ConnectionProvider newConnectionProvider)
Create a derived configuration from this one, with a new connection provider.Configuration
derive(ConverterProvider newConverterProvider)
Create a derived configuration from this one, with new converter provider.Configuration
derive(DiagnosticsListener... newDiagnosticsListeners)
Create a derived configuration from this one, with new diagnostics listeners.Configuration
derive(DiagnosticsListenerProvider... newDiagnosticsListenerProviders)
Create a derived configuration from this one, with new diagnostics listener providers.Configuration
derive(ExecuteListener... newExecuteListeners)
Create a derived configuration from this one, with new execute listeners.Configuration
derive(ExecuteListenerProvider... newExecuteListenerProviders)
Create a derived configuration from this one, with new execute listener providers.Configuration
derive(ExecutorProvider newExecutorProvider)
Create a derived configuration from this one, with a new executor provider.Configuration
derive(MetaProvider newMetaProvider)
Create a derived configuration from this one, with a new meta provider.Configuration
derive(RecordListener... newRecordListeners)
Create a derived configuration from this one, with new record listeners.Configuration
derive(RecordListenerProvider... newRecordListenerProviders)
Create a derived configuration from this one, with new record listener providers.Configuration
derive(RecordMapper<?,?> newRecordMapper)
Create a derived configuration from this one, with a new record mapper.Configuration
derive(RecordMapperProvider newRecordMapperProvider)
Create a derived configuration from this one, with a new record mapper provider.Configuration
derive(RecordUnmapper<?,?> newRecordUnmapper)
Create a derived configuration from this one, with a new record unmapper.Configuration
derive(RecordUnmapperProvider newRecordUnmapperProvider)
Create a derived configuration from this one, with a new record unmapper provider.Configuration
derive(SQLDialect newDialect)
Create a derived configuration from this one, with a new dialect.Configuration
derive(TransactionListener... newTransactionListeners)
Create a derived configuration from this one, with new transaction listeners.Configuration
derive(TransactionListenerProvider... newTransactionListenerProviders)
Create a derived configuration from this one, with new transaction listener providers.Configuration
derive(TransactionProvider newTransactionProvider)
Create a derived configuration from this one, with a new transaction provider.Configuration
derive(Unwrapper newUnwrapper)
Create a derived configuration from this one, with a new unwrapper.Configuration
derive(UnwrapperProvider newUnwrapperProvider)
Create a derived configuration from this one, with a new unwrapper provider.Configuration
derive(VisitListener... newVisitListeners)
Create a derived configuration from this one, with new visit listeners.Configuration
derive(VisitListenerProvider... newVisitListenerProviders)
Create a derived configuration from this one, with new visit listener providers.DiagnosticsListenerProvider[]
diagnosticsListenerProviders()
Get the configuredDiagnosticsListenerProvider
s from this configuration.SQLDialect
dialect()
Retrieve the configured dialect.DSLContext
dsl()
Wrap thisConfiguration
in aDSLContext
, providing access to the configuration-contextual DSL to construct executable queries.ExecuteListenerProvider[]
executeListenerProviders()
Get the configuredExecuteListenerProvider
s from this configuration.ExecutorProvider
executorProvider()
Get this configuration's underlying executor provider.SQLDialect
family()
Retrieve the family of the configured dialect.MetaProvider
metaProvider()
Get this configuration's underlying meta provider.RecordListenerProvider[]
recordListenerProviders()
Get the configuredRecordListenerProvider
s from this configuration.RecordMapperProvider
recordMapperProvider()
Get this configuration's underlying record mapper provider.RecordUnmapperProvider
recordUnmapperProvider()
Get this configuration's underlying record unmapper provider.SchemaMapping
schemaMapping()
Retrieve the configured schema mapping.Configuration
set(Connection newConnection)
Change this configuration to hold a new connection wrapped in aDefaultConnectionProvider
.Configuration
set(Clock newClock)
Change this configuration to hold a newClock
.Configuration
set(Executor newExecutor)
Change this configuration to hold a new executor.Configuration
set(DataSource newDataSource)
Change this configuration to hold a new data source wrapped in aDataSourceConnectionProvider
.Configuration
set(Settings newSettings)
Change this configuration to hold a new settings.Configuration
set(ConnectionProvider newConnectionProvider)
Change this configuration to hold a new connection provider.Configuration
set(ConverterProvider newConverterProvider)
Change this configuration to hold a new converter provider.Configuration
set(DiagnosticsListener... newDiagnosticsListeners)
Change this configuration to hold a new diagnostics listeners.Configuration
set(DiagnosticsListenerProvider... newDiagnosticsListenerProviders)
Change this configuration to hold new diagnostics listener providers.Configuration
set(ExecuteListener... newExecuteListeners)
Change this configuration to hold a new execute listeners.Configuration
set(ExecuteListenerProvider... newExecuteListenerProviders)
Change this configuration to hold a new execute listener providers.Configuration
set(ExecutorProvider newExecutorProvider)
Change this configuration to hold a new executor provider.Configuration
set(MetaProvider newMetaProvider)
Change this configuration to hold a new meta provider.Configuration
set(RecordListener... newRecordListeners)
Change this configuration to hold a new record listeners.Configuration
set(RecordListenerProvider... newRecordListenerProviders)
Change this configuration to hold a new record listener providers.Configuration
set(RecordMapper<?,?> newRecordMapper)
Change this configuration to hold a new record mapper.Configuration
set(RecordMapperProvider newRecordMapperProvider)
Change this configuration to hold a new record mapper provider.Configuration
set(RecordUnmapper<?,?> newRecordUnmapper)
Change this configuration to hold a new record unmapper.Configuration
set(RecordUnmapperProvider newRecordUnmapperProvider)
Change this configuration to hold a new record unmapper provider.Configuration
set(SQLDialect newDialect)
Change this configuration to hold a new dialect.Configuration
set(TransactionListener... newTransactionListeners)
Change this configuration to hold a new transaction listeners.Configuration
set(TransactionListenerProvider... newTransactionListenerProviders)
Change this configuration to hold a new transaction listener providers.Configuration
set(TransactionProvider newTransactionProvider)
Change this configuration to hold a new transaction provider.Configuration
set(Unwrapper newUnwrapper)
Change this configuration to hold a new unwrapper.Configuration
set(UnwrapperProvider newUnwrapperProvider)
Change this configuration to hold a new unwrapper provider.Configuration
set(VisitListener... newVisitListeners)
Change this configuration to hold a new visit listeners.Configuration
set(VisitListenerProvider... newVisitListenerProviders)
Change this configuration to hold a new visit listener providers.Settings
settings()
Retrieve the runtime configuration settings.TransactionListenerProvider[]
transactionListenerProviders()
Get the configuredTransactionListenerProvider
s from this configuration.TransactionProvider
transactionProvider()
Get this configuration's underlying transaction provider.UnwrapperProvider
unwrapperProvider()
Get the configuredUnwrapperProvider
from this configuration.VisitListenerProvider[]
visitListenerProviders()
Get the configuredVisitListenerProvider
instances from this configuration.
-
-
-
Constructor Detail
-
MockConfiguration
public MockConfiguration(Configuration delegate, MockDataProvider provider)
-
-
Method Detail
-
dsl
public DSLContext dsl()
Description copied from interface:Configuration
Wrap thisConfiguration
in aDSLContext
, providing access to the configuration-contextual DSL to construct executable queries.In the
DefaultConfiguration
implementation, this is just convenience forDSL.using(Configuration)
. There's no functional difference between the two methods.- Specified by:
dsl
in interfaceConfiguration
-
data
public Map<Object,Object> data()
Description copied from interface:Configuration
Get all custom data from thisConfiguration
.This is custom data that was previously set to the configuration using
Configuration.data(Object, Object)
. Use custom data if you want to pass data to your customQueryPart
orExecuteListener
objects to be made available at render, bind, execution, fetch time.See
ExecuteListener
for more details.- Specified by:
data
in interfaceConfiguration
- Returns:
- The custom data. This is never
null
- See Also:
ExecuteListener
-
data
public Object data(Object key)
Description copied from interface:Configuration
Get some custom data from thisConfiguration
.This is custom data that was previously set to the configuration using
Configuration.data(Object, Object)
. Use custom data if you want to pass data to your customQueryPart
orExecuteListener
objects to be made available at render, bind, execution, fetch time.See
ExecuteListener
for more details.- Specified by:
data
in interfaceConfiguration
- Parameters:
key
- A key to identify the custom data- Returns:
- The custom data or
null
if no such data is contained in thisConfiguration
- See Also:
ExecuteListener
-
data
public Object data(Object key, Object value)
Description copied from interface:Configuration
Set some custom data to thisConfiguration
.Use custom data if you want to pass data to your custom
QueryPart
orExecuteListener
objects to be made available at render, bind, execution, fetch time.Be sure that your custom data implements
Serializable
if you want to serialise thisConfiguration
or objects referencing thisConfiguration
, e.g. yourRecord
types.See
ExecuteListener
for more details.- Specified by:
data
in interfaceConfiguration
- Parameters:
key
- A key to identify the custom datavalue
- The custom data- Returns:
- The previously set custom data or
null
if no data was previously set for the given key - See Also:
ExecuteListener
-
clock
public Clock clock()
Description copied from interface:Configuration
Get this configuration'sClock
, which is used for optimistic locking, transaction time, and other time-depending features.- Specified by:
clock
in interfaceConfiguration
-
connectionProvider
public ConnectionProvider connectionProvider()
Description copied from interface:Configuration
Get this configuration's underlying connection provider.- Specified by:
connectionProvider
in interfaceConfiguration
-
metaProvider
public MetaProvider metaProvider()
Description copied from interface:Configuration
Get this configuration's underlying meta provider.- Specified by:
metaProvider
in interfaceConfiguration
-
executorProvider
public ExecutorProvider executorProvider()
Description copied from interface:Configuration
Get this configuration's underlying executor provider.Asynchronous operations will call back to this SPI to obtain an executor. This applies, for example, to
ResultQuery.fetchAsync()
.The following logic is applied when resolving the appropriate
executor
:- If
Configuration.executorProvider()
does not returnnull
, thenExecutorProvider.provide()
is called to obtain anExecutor
for the asynchronous task. - In the jOOQ Java 8 distribution,
ForkJoinPool.commonPool()
is used ifForkJoinPool.getCommonPoolParallelism()
> 1 - A new "one thread per call"
Executor
is used in any other case.
The SPI will not be called if an asynchronous operation explicitly overrides the
Executor
, e.g. as is the case forResultQuery.fetchAsync(Executor)
.- Specified by:
executorProvider
in interfaceConfiguration
- If
-
transactionProvider
public TransactionProvider transactionProvider()
Description copied from interface:Configuration
Get this configuration's underlying transaction provider.If no explicit transaction provider was specified, and if
Configuration.connectionProvider()
is aDefaultConnectionProvider
, then this will return aDefaultTransactionProvider
.- Specified by:
transactionProvider
in interfaceConfiguration
-
recordMapperProvider
public RecordMapperProvider recordMapperProvider()
Description copied from interface:Configuration
Get this configuration's underlying record mapper provider.- Specified by:
recordMapperProvider
in interfaceConfiguration
-
recordUnmapperProvider
public RecordUnmapperProvider recordUnmapperProvider()
Description copied from interface:Configuration
Get this configuration's underlying record unmapper provider.- Specified by:
recordUnmapperProvider
in interfaceConfiguration
-
recordListenerProviders
public RecordListenerProvider[] recordListenerProviders()
Description copied from interface:Configuration
Get the configuredRecordListenerProvider
s from this configuration.This method allows for retrieving the configured
RecordListenerProvider
from this configuration. The providers will provide jOOQ withRecordListener
instances. These instances receive record manipulation notification events every time jOOQ executes queries. jOOQ makes no assumptions about the internal state of these listeners, i.e. listener instances may- share this
Configuration
's lifecycle (i.e. that of a JDBCConnection
, or that of a transaction) - share the lifecycle of an
RecordContext
(i.e. that of a single record manipulation) - follow an entirely different lifecycle.
- Specified by:
recordListenerProviders
in interfaceConfiguration
- Returns:
- The configured set of record listeners.
- See Also:
RecordListenerProvider
,RecordListener
,RecordContext
- share this
-
executeListenerProviders
public ExecuteListenerProvider[] executeListenerProviders()
Description copied from interface:Configuration
Get the configuredExecuteListenerProvider
s from this configuration.This method allows for retrieving the configured
ExecuteListenerProvider
from this configuration. The providers will provide jOOQ withExecuteListener
instances. These instances receive execution lifecycle notification events every time jOOQ executes queries. jOOQ makes no assumptions about the internal state of these listeners, i.e. listener instances may- share this
Configuration
's lifecycle (i.e. that of a JDBCConnection
, or that of a transaction) - share the lifecycle of an
ExecuteContext
(i.e. that of a single query execution) - follow an entirely different lifecycle.
Note, depending on your
Settings.isExecuteLogging()
, some additional listeners may be prepended to this list, internally. Those listeners will never be exposed through this method, though.- Specified by:
executeListenerProviders
in interfaceConfiguration
- Returns:
- The configured set of execute listeners.
- See Also:
ExecuteListenerProvider
,ExecuteListener
,ExecuteContext
- share this
-
visitListenerProviders
public VisitListenerProvider[] visitListenerProviders()
Description copied from interface:Configuration
Get the configuredVisitListenerProvider
instances from this configuration.This method allows for retrieving the configured
VisitListenerProvider
instances from this configuration. The providers will provide jOOQ withVisitListener
instances. These instances receive query rendering lifecycle notification events every time jOOQ renders queries. jOOQ makes no assumptions about the internal state of these listeners, i.e. listener instances may- share this
Configuration
's lifecycle (i.e. that of a JDBCConnection
, or that of a transaction) - share the lifecycle of an
ExecuteContext
(i.e. that of a single query execution) - follow an entirely different lifecycle.
- Specified by:
visitListenerProviders
in interfaceConfiguration
- Returns:
- The configured set of visit listeners.
- See Also:
VisitListenerProvider
,VisitListener
,VisitContext
- share this
-
transactionListenerProviders
public TransactionListenerProvider[] transactionListenerProviders()
Description copied from interface:Configuration
Get the configuredTransactionListenerProvider
s from this configuration.- Specified by:
transactionListenerProviders
in interfaceConfiguration
-
diagnosticsListenerProviders
public DiagnosticsListenerProvider[] diagnosticsListenerProviders()
Description copied from interface:Configuration
Get the configuredDiagnosticsListenerProvider
s from this configuration.- Specified by:
diagnosticsListenerProviders
in interfaceConfiguration
-
unwrapperProvider
public UnwrapperProvider unwrapperProvider()
Description copied from interface:Configuration
Get the configuredUnwrapperProvider
from this configuration.- Specified by:
unwrapperProvider
in interfaceConfiguration
-
converterProvider
public ConverterProvider converterProvider()
Description copied from interface:Configuration
Get the configuredConverterProvider
from this configuration.- Specified by:
converterProvider
in interfaceConfiguration
-
schemaMapping
public SchemaMapping schemaMapping()
Description copied from interface:Configuration
Retrieve the configured schema mapping.- Specified by:
schemaMapping
in interfaceConfiguration
-
dialect
public SQLDialect dialect()
Description copied from interface:Configuration
Retrieve the configured dialect.- Specified by:
dialect
in interfaceConfiguration
-
family
public SQLDialect family()
Description copied from interface:Configuration
Retrieve the family of the configured dialect.- Specified by:
family
in interfaceConfiguration
-
settings
public Settings settings()
Description copied from interface:Configuration
Retrieve the runtime configuration settings.- Specified by:
settings
in interfaceConfiguration
-
set
public Configuration set(Clock newClock)
Description copied from interface:Configuration
Change this configuration to hold a newClock
.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newClock
- The new clock to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(ConnectionProvider newConnectionProvider)
Description copied from interface:Configuration
Change this configuration to hold a new connection provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newConnectionProvider
- The new connection provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(MetaProvider newMetaProvider)
Description copied from interface:Configuration
Change this configuration to hold a new meta provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newMetaProvider
- The new meta provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(Connection newConnection)
Description copied from interface:Configuration
Change this configuration to hold a new connection wrapped in aDefaultConnectionProvider
.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newConnection
- The new connection to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(DataSource newDataSource)
Description copied from interface:Configuration
Change this configuration to hold a new data source wrapped in aDataSourceConnectionProvider
.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newDataSource
- The new data source to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(Executor newExecutor)
Description copied from interface:Configuration
Change this configuration to hold a new executor.This will wrap the argument
Executor
in aDefaultExecutorProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newExecutor
- The new executor to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(ExecutorProvider newExecutorProvider)
Description copied from interface:Configuration
Change this configuration to hold a new executor provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newExecutorProvider
- The new executor provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(TransactionProvider newTransactionProvider)
Description copied from interface:Configuration
Change this configuration to hold a new transaction provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newTransactionProvider
- The new transaction provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordMapper<?,?> newRecordMapper)
Description copied from interface:Configuration
Change this configuration to hold a new record mapper.This will wrap the argument
RecordMapper
in aDefaultRecordMapperProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordMapper
- The new record mapper to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordMapperProvider newRecordMapperProvider)
Description copied from interface:Configuration
Change this configuration to hold a new record mapper provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordMapperProvider
- The new record mapper provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordUnmapper<?,?> newRecordUnmapper)
Description copied from interface:Configuration
Change this configuration to hold a new record unmapper.This will wrap the argument
RecordUnmapper
in aDefaultRecordUnmapperProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordUnmapper
- The new record unmapper to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordUnmapperProvider newRecordUnmapperProvider)
Description copied from interface:Configuration
Change this configuration to hold a new record unmapper provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordUnmapperProvider
- The new record unmapper provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordListener... newRecordListeners)
Description copied from interface:Configuration
Change this configuration to hold a new record listeners.This will wrap the argument
RecordListener
in aDefaultRecordListenerProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordListeners
- The new record listener to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(RecordListenerProvider... newRecordListenerProviders)
Description copied from interface:Configuration
Change this configuration to hold a new record listener providers.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newRecordListenerProviders
- The new record listener providers to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(ExecuteListener... newExecuteListeners)
Description copied from interface:Configuration
Change this configuration to hold a new execute listeners.This will wrap the argument
ExecuteListener
in aDefaultExecuteListenerProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newExecuteListeners
- The new execute listeners to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(ExecuteListenerProvider... newExecuteListenerProviders)
Description copied from interface:Configuration
Change this configuration to hold a new execute listener providers.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newExecuteListenerProviders
- The new execute listener providers to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(VisitListener... newVisitListeners)
Description copied from interface:Configuration
Change this configuration to hold a new visit listeners.This will wrap the argument
VisitListener
in aDefaultVisitListenerProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newVisitListeners
- The new visit listeners to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(VisitListenerProvider... newVisitListenerProviders)
Description copied from interface:Configuration
Change this configuration to hold a new visit listener providers.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newVisitListenerProviders
- The new visit listener providers to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(TransactionListener... newTransactionListeners)
Description copied from interface:Configuration
Change this configuration to hold a new transaction listeners.This will wrap the argument
TransactionListener
in aDefaultTransactionListenerProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newTransactionListeners
- The new transaction listeners to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(TransactionListenerProvider... newTransactionListenerProviders)
Description copied from interface:Configuration
Change this configuration to hold a new transaction listener providers.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newTransactionListenerProviders
- The new transaction listener providers to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(DiagnosticsListener... newDiagnosticsListeners)
Description copied from interface:Configuration
Change this configuration to hold a new diagnostics listeners.This will wrap the argument
DiagnosticsListener
in aDefaultDiagnosticsListenerProvider
for convenience.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newDiagnosticsListeners
- The new diagnostics listeners to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(DiagnosticsListenerProvider... newDiagnosticsListenerProviders)
Description copied from interface:Configuration
Change this configuration to hold new diagnostics listener providers.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newDiagnosticsListenerProviders
- The new diagnostics listener providers to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(Unwrapper newUnwrapper)
Description copied from interface:Configuration
Change this configuration to hold a new unwrapper.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newUnwrapper
- The new unwrapper to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(UnwrapperProvider newUnwrapperProvider)
Description copied from interface:Configuration
Change this configuration to hold a new unwrapper provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newUnwrapperProvider
- The new unwrapper provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(ConverterProvider newConverterProvider)
Description copied from interface:Configuration
Change this configuration to hold a new converter provider.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newConverterProvider
- The new converter provider to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(SQLDialect newDialect)
Description copied from interface:Configuration
Change this configuration to hold a new dialect.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newDialect
- The new dialect to be contained in the changed configuration.- Returns:
- The changed configuration.
-
set
public Configuration set(Settings newSettings)
Description copied from interface:Configuration
Change this configuration to hold a new settings.This method is not thread-safe and should not be used in globally available
Configuration
objects.- Specified by:
set
in interfaceConfiguration
- Parameters:
newSettings
- The new settings to be contained in the changed configuration.- Returns:
- The changed configuration.
-
derive
public Configuration derive()
Description copied from interface:Configuration
Create a derived configuration from this one, without changing any properties.- Specified by:
derive
in interfaceConfiguration
- Returns:
- The derived configuration.
-
derive
public Configuration derive(Clock newClock)
Description copied from interface:Configuration
Create a derived configuration from this one, with a newClock
.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newClock
- The new clock to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(Connection newConnection)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new connection wrapped in aDefaultConnectionProvider
.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newConnection
- The new connection to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(DataSource newDataSource)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new data source wrapped in aDataSourceConnectionProvider
.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newDataSource
- The new data source to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(ConnectionProvider newConnectionProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new connection provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newConnectionProvider
- The new connection provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(MetaProvider newMetaProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new meta provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newMetaProvider
- The new meta provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(Executor newExecutor)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new executor.This will wrap the argument
Executor
in aDefaultExecutorProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newExecutor
- The new executor to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(ExecutorProvider newExecutorProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new executor provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newExecutorProvider
- The new executor provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(TransactionProvider newTransactionProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new transaction provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newTransactionProvider
- The new transaction provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordMapper<?,?> newRecordMapper)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new record mapper.This will wrap the argument
RecordMapper
in aDefaultRecordMapperProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordMapper
- The new record mapper to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordMapperProvider newRecordMapperProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new record mapper provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordMapperProvider
- The new record mapper provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordUnmapper<?,?> newRecordUnmapper)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new record unmapper.This will wrap the argument
RecordUnmapper
in aDefaultRecordUnmapperProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordUnmapper
- The new record unmapper to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordUnmapperProvider newRecordUnmapperProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new record unmapper provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordUnmapperProvider
- The new record unmapper provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordListener... newRecordListeners)
Description copied from interface:Configuration
Create a derived configuration from this one, with new record listeners.This will wrap the argument
RecordListener
in aDefaultRecordListenerProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordListeners
- The new record listeners to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(RecordListenerProvider... newRecordListenerProviders)
Description copied from interface:Configuration
Create a derived configuration from this one, with new record listener providers.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newRecordListenerProviders
- The new record listener providers to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(ExecuteListener... newExecuteListeners)
Description copied from interface:Configuration
Create a derived configuration from this one, with new execute listeners.This will wrap the argument
ExecuteListener
in aDefaultExecuteListenerProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newExecuteListeners
- The new execute listener to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(ExecuteListenerProvider... newExecuteListenerProviders)
Description copied from interface:Configuration
Create a derived configuration from this one, with new execute listener providers.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newExecuteListenerProviders
- The new execute listener providers to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(VisitListener... newVisitListeners)
Description copied from interface:Configuration
Create a derived configuration from this one, with new visit listeners.This will wrap the argument
VisitListener
in aDefaultVisitListenerProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newVisitListeners
- The new visit listeners to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(VisitListenerProvider... newVisitListenerProviders)
Description copied from interface:Configuration
Create a derived configuration from this one, with new visit listener providers.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newVisitListenerProviders
- The new visit listener providers to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(TransactionListener... newTransactionListeners)
Description copied from interface:Configuration
Create a derived configuration from this one, with new transaction listeners.This will wrap the argument
TransactionListener
in aDefaultTransactionListenerProvider
for convenience.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newTransactionListeners
- The new transaction listeners to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(TransactionListenerProvider... newTransactionListenerProviders)
Description copied from interface:Configuration
Create a derived configuration from this one, with new transaction listener providers.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newTransactionListenerProviders
- The new transaction listener providers to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(DiagnosticsListener... newDiagnosticsListeners)
Description copied from interface:Configuration
Create a derived configuration from this one, with new diagnostics listeners.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newDiagnosticsListeners
- The new diagnostics listeners to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(DiagnosticsListenerProvider... newDiagnosticsListenerProviders)
Description copied from interface:Configuration
Create a derived configuration from this one, with new diagnostics listener providers.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newDiagnosticsListenerProviders
- The new diagnostics listener providers to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(Unwrapper newUnwrapper)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new unwrapper.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newUnwrapper
- The new unwrapper to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(UnwrapperProvider newUnwrapperProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new unwrapper provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newUnwrapperProvider
- The new unwrapper provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(ConverterProvider newConverterProvider)
Description copied from interface:Configuration
Create a derived configuration from this one, with new converter provider.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newConverterProvider
- The new converter provider to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(SQLDialect newDialect)
Description copied from interface:Configuration
Create a derived configuration from this one, with a new dialect.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newDialect
- The new dialect to be contained in the derived configuration.- Returns:
- The derived configuration.
-
derive
public Configuration derive(Settings newSettings)
Description copied from interface:Configuration
Create a derived configuration from this one, with new settings.- Specified by:
derive
in interfaceConfiguration
- Parameters:
newSettings
- The new settings to be contained in the derived configuration.- Returns:
- The derived configuration.
-
-