public class InlineIdsInClauseBulkIdStrategy extends Object implements MultiTableBulkIdStrategy
This bulk-id strategy inlines identifiers of the rows that need to be updated or deleted using an IN clause:
<pre> delete from Doctor where ( id ) in ( ( 1 ), ( 2 ), ( 3 ), ( 4 ) ) </pre>
MultiTableBulkIdStrategy.DeleteHandler, MultiTableBulkIdStrategy.UpdateHandler| Modifier and Type | Field and Description |
|---|---|
static InlineIdsInClauseBulkIdStrategy |
INSTANCE |
| Constructor and Description |
|---|
InlineIdsInClauseBulkIdStrategy() |
| Modifier and Type | Method and Description |
|---|---|
MultiTableBulkIdStrategy.DeleteHandler |
buildDeleteHandler(SessionFactoryImplementor factory,
org.hibernate.hql.internal.ast.HqlSqlWalker walker)
Build a handler capable of handling the bulk delete indicated by the given walker.
|
MultiTableBulkIdStrategy.UpdateHandler |
buildUpdateHandler(SessionFactoryImplementor factory,
org.hibernate.hql.internal.ast.HqlSqlWalker walker)
Build a handler capable of handling the bulk update indicated by the given walker.
|
void |
prepare(JdbcServices jdbcServices,
JdbcConnectionAccess jdbcConnectionAccess,
MetadataImplementor metadataImplementor,
SessionFactoryOptions sessionFactoryOptions)
Prepare the strategy.
|
void |
release(JdbcServices jdbcServices,
JdbcConnectionAccess connectionAccess)
Release the strategy.
|
public static final InlineIdsInClauseBulkIdStrategy INSTANCE
public void prepare(JdbcServices jdbcServices, JdbcConnectionAccess jdbcConnectionAccess, MetadataImplementor metadataImplementor, SessionFactoryOptions sessionFactoryOptions)
MultiTableBulkIdStrategyPrepare the strategy. Called as the SessionFactory is being built. Intended patterns here include:<ul> <li>Adding tables to the passed Mappings, to be picked by by "schema management tools"</li> <li>Manually creating the tables immediately through the passed JDBC Connection access</li> </ul>
prepare in interface MultiTableBulkIdStrategyjdbcServices - The JdbcService objectjdbcConnectionAccess - Access to the JDBC ConnectionmetadataImplementor - Access to the O/RM mapping informationpublic void release(JdbcServices jdbcServices, JdbcConnectionAccess connectionAccess)
MultiTableBulkIdStrategyRelease the strategy. Called as the SessionFactory is being shut down.
release in interface MultiTableBulkIdStrategyjdbcServices - The JdbcService objectconnectionAccess - Access to the JDBC Connectionpublic MultiTableBulkIdStrategy.UpdateHandler buildUpdateHandler(SessionFactoryImplementor factory, org.hibernate.hql.internal.ast.HqlSqlWalker walker)
MultiTableBulkIdStrategyBuild a handler capable of handling the bulk update indicated by the given walker.
buildUpdateHandler in interface MultiTableBulkIdStrategyfactory - The SessionFactorywalker - The AST walker, representing the update querypublic MultiTableBulkIdStrategy.DeleteHandler buildDeleteHandler(SessionFactoryImplementor factory, org.hibernate.hql.internal.ast.HqlSqlWalker walker)
MultiTableBulkIdStrategyBuild a handler capable of handling the bulk delete indicated by the given walker.
buildDeleteHandler in interface MultiTableBulkIdStrategyfactory - The SessionFactorywalker - The AST walker, representing the delete queryCopyright © 2001-2018 Red Hat, Inc. All Rights Reserved.