for (int i = 0, n = statementList.size(); i < n; i++) {
Statement stmt = statementList.get(i);
BatchResult batchResult = batchResultList.get(i);
try {
batchResult.setUpdateCounts(stmt.executeBatch());
MappedStatement ms = batchResult.getMappedStatement();
Object parameter = batchResult.getParameterObject();
KeyGenerator keyGenerator = ms.getKeyGenerator();
if (keyGenerator instanceof Jdbc3KeyGenerator) {
keyGenerator.processAfter(this, ms, stmt, parameter);
}
} catch (BatchUpdateException e) {
StringBuffer message = new StringBuffer();