java.lang.Object
org.itsallcode.jdbc.batch.StatementBatch
- All Implemented Interfaces:
AutoCloseable
A batch handler for SQL statements.
-
Constructor Summary
ConstructorsConstructorDescriptionStatementBatch(SimpleStatement statement, int maxBatchSize) Create a new instance. -
Method Summary
-
Constructor Details
-
StatementBatch
Create a new instance.- Parameters:
statement- the statementmaxBatchSize- maximum batch size
-
-
Method Details
-
addBatch
Add a new SQL statement to the batch.- Parameters:
sql- SQL statement
-
close
- Specified by:
closein interfaceAutoCloseable
-