public void close() { if (resultSet != null) { try { resultSet.close(); } catch (SQLException e) { LOGGER.error("error closing inner resultset in iterator: " + e.getMessage()); } } finished = true; }
private void getNextItem() { try { if (resultSet.next()) { nextValue = resultSet.getString(KEY_COLUMN); } else { close(); } } catch (SQLException e) { finished = true; LOGGER.warn("unexpected error during result set iteration: " + e.getMessage()); } updateStats(true, false); }