BatchPreparedStatementSetter interface,
adding a batch exhaustion check.
This interface allows you to signal the end of a batch rather than having to determine the exact batch size upfront. Batch size is still being honored but it is now the maximum size of the batch.
The isBatchExhausted method is called after each call to
setValues to determine whether there were some values added,
or if the batch was determined to be complete and no additional values
were provided during the last call to setValues.
Consider extending the
org.
base class instead of implementing this interface directly, using a single
setValuesIfAvailable callback method that checks for available
values and sets them, returning whether values have actually been provided.
JdbcTemplate#batchUpdate(String, BatchPreparedStatementSetter), org.springframework.jdbc.core.support.AbstractInterruptibleBatchPreparedStatementSetter
| Modifier and Type | Method and Description |
|---|---|
| public boolean | Returns: whether the batch is already exhaustedindex of the statement we're issuing in the batch, starting from 0 i)Return whether the batch is complete, that is, whether there were no
additional values added during the last |
| isBatchExhausted | back to summary |
|---|---|
| public boolean isBatchExhausted(int i) Return whether the batch is complete, that is, whether there were no
additional values added during the last Note If this method returns
| |