Class BatchImpl
- java.lang.Object
-
- org.hibernate.engine.jdbc.batch.internal.BatchImpl
-
-
Constructor Summary
Constructors Constructor Description BatchImpl(BatchKey key, PreparedStatementGroup statementGroup, int batchSizeToUse, JdbcCoordinator jdbcCoordinator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
abortBatch(Exception cause)
void
addObserver(BatchObserver observer)
Adds an observer to this batch.void
addToBatch(JdbcValueBindings jdbcValueBindings, TableInclusionChecker inclusionChecker)
Apply the value bindings to the batch JDBC statements and indicates completion of the current part of the batch.protected void
clearBatch(PreparedStatementDetails statementDetails)
void
execute()
Execute this batch.BatchKey
getKey()
Retrieves the object being used to key (uniquely identify) this batch.PreparedStatementGroup
getStatementGroup()
protected void
notifyObserversExplicitExecution()
Convenience method to notify registered observers of an explicit execution of this batch.protected void
notifyObserversImplicitExecution()
Convenience method to notify registered observers of an implicit execution of this batch.protected void
performExecution()
void
release()
Used to indicate that the batch instance is no longer needed and that, therefore, it can release its resources.protected void
releaseStatements()
String
toString()
-
-
-
Constructor Detail
-
BatchImpl
public BatchImpl(BatchKey key, PreparedStatementGroup statementGroup, int batchSizeToUse, JdbcCoordinator jdbcCoordinator)
-
-
Method Detail
-
getKey
public final BatchKey getKey()
Description copied from interface:Batch
Retrieves the object being used to key (uniquely identify) this batch.
-
getStatementGroup
public PreparedStatementGroup getStatementGroup()
- Specified by:
getStatementGroup
in interfaceBatch
-
addObserver
public void addObserver(BatchObserver observer)
Description copied from interface:Batch
Adds an observer to this batch.- Specified by:
addObserver
in interfaceBatch
- Parameters:
observer
- The batch observer.
-
addToBatch
public void addToBatch(JdbcValueBindings jdbcValueBindings, TableInclusionChecker inclusionChecker)
Description copied from interface:Batch
Apply the value bindings to the batch JDBC statements and indicates completion of the current part of the batch.- Specified by:
addToBatch
in interfaceBatch
-
releaseStatements
protected void releaseStatements()
-
clearBatch
protected void clearBatch(PreparedStatementDetails statementDetails)
-
notifyObserversExplicitExecution
protected final void notifyObserversExplicitExecution()
Convenience method to notify registered observers of an explicit execution of this batch.
-
notifyObserversImplicitExecution
protected final void notifyObserversImplicitExecution()
Convenience method to notify registered observers of an implicit execution of this batch.
-
abortBatch
protected void abortBatch(Exception cause)
-
execute
public void execute()
Description copied from interface:Batch
Execute this batch.
-
performExecution
protected void performExecution()
-
release
public void release()
Description copied from interface:Batch
Used to indicate that the batch instance is no longer needed and that, therefore, it can release its resources.
-
-