code: public void close() {
          while (getCurrentResultSet() != null) {
              try {
                  closeResultSet(getCurrentResultSet());
  
                  setCurrentResultSet(getNextResultSet());
              } catch (SQLException ex) {
                  // considering that all ResultSets are closed
                  setCurrentResultSet(null);
              }
          }
  
          MjdbcUtils.closeQuietly(stmt);
      }
docs: Performs cleanup of all resources used by this lazy query output list implementation: {@link Statement} and {@link ResultSet}