<commit_before>package org.opendaylight.controller.md.sal.dom.xsql.jdbc;

import java.io.InputStream;
import java.io.Reader;
import java.io.Serializable;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
import java.math.BigDecimal;
import java.net.URL;
import java.sql.Array;
import java.sql.Blob;
import java.sql.Clob;
import java.sql.Date;
import java.sql.NClob;
import java.sql.Ref;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.RowId;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.SQLXML;
import java.sql.Statement;
import java.sql.Time;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;

import org.opendaylight.controller.md.sal.dom.xsql.XSQLBluePrint;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLBluePrintNode;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLColumn;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLCriteria;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLODLUtils;

public class JDBCResultSet implements Serializable, ResultSet,
        ResultSetMetaData {
    private static final long serialVersionUID = -7450200738431047057L;

    private String sql = null;
    private List<XSQLBluePrintNode> tablesInQuery = new ArrayList<XSQLBluePrintNode>();
    private Map<String, XSQLBluePrintNode> tablesInQueryMap = new ConcurrentHashMap<String, XSQLBluePrintNode>();
    private List<XSQLColumn> fieldsInQuery = new ArrayList<XSQLColumn>();
    private transient LinkedList<Map<String, Object>> records = new LinkedList<>();
    private transient Map<String, Object> currentRecord = null;
    private boolean finished = false;
    private int id = 0;
    private static Integer nextID = new Integer(0);
    public int numberOfTasks = 0;
    private Map<String, Map<XSQLColumn, List<XSQLCriteria>>> criteria = new ConcurrentHashMap<String, Map<XSQLColumn, List<XSQLCriteria>>>();
    private Exception err = null;
    private List<Record> EMPTY_RESULT = new LinkedList<Record>();
    private transient Map<String,JDBCResultSet> subQueries = new HashMap<String,JDBCResultSet>();

    public ResultSet getProxy() {
         return (ResultSet) Proxy.newProxyInstance(this.getClass().getClassLoader(), new Class[] {ResultSet.class }, new JDBCProxy(this));
    }

    public void setSQL(String _sql) {
        this.sql = _sql;
    }

    public JDBCResultSet addSubQuery(String _sql,String logicalName) {
        if (subQueries == null) {
            subQueries = new HashMap<String,JDBCResultSet>();
        }
        JDBCResultSet rs = new JDBCResultSet(_sql);
        this.subQueries.put(logicalName,rs);
        return rs;<commit_msg>XSQL: prevent autoboxing<commit_after>package org.opendaylight.controller.md.sal.dom.xsql.jdbc;

import java.io.InputStream;
import java.io.Reader;
import java.io.Serializable;
import java.lang.reflect.Method;
import java.lang.reflect.Proxy;
import java.math.BigDecimal;
import java.net.URL;
import java.sql.Array;
import java.sql.Blob;
import java.sql.Clob;
import java.sql.Date;
import java.sql.NClob;
import java.sql.Ref;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.RowId;
import java.sql.SQLException;
import java.sql.SQLWarning;
import java.sql.SQLXML;
import java.sql.Statement;
import java.sql.Time;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.concurrent.ConcurrentHashMap;

import org.opendaylight.controller.md.sal.dom.xsql.XSQLBluePrint;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLBluePrintNode;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLColumn;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLCriteria;
import org.opendaylight.controller.md.sal.dom.xsql.XSQLODLUtils;

public class JDBCResultSet implements Serializable, ResultSet,
        ResultSetMetaData {
    private static final long serialVersionUID = -7450200738431047057L;
    private static int nextID = 0;

    private String sql = null;
    private List<XSQLBluePrintNode> tablesInQuery = new ArrayList<XSQLBluePrintNode>();
    private Map<String, XSQLBluePrintNode> tablesInQueryMap = new ConcurrentHashMap<String, XSQLBluePrintNode>();
    private List<XSQLColumn> fieldsInQuery = new ArrayList<XSQLColumn>();
    private transient LinkedList<Map<String, Object>> records = new LinkedList<>();
    private transient Map<String, Object> currentRecord = null;
    private boolean finished = false;
    private int id = 0;
    public int numberOfTasks = 0;
    private Map<String, Map<XSQLColumn, List<XSQLCriteria>>> criteria = new ConcurrentHashMap<String, Map<XSQLColumn, List<XSQLCriteria>>>();
    private Exception err = null;
    private List<Record> EMPTY_RESULT = new LinkedList<Record>();
    private transient Map<String,JDBCResultSet> subQueries = new HashMap<String,JDBCResultSet>();

    public ResultSet getProxy() {
         return (ResultSet) Proxy.newProxyInstance(this.getClass().getClassLoader(), new Class[] {ResultSet.class }, new JDBCProxy(this));
    }

    public void setSQL(String _sql) {
        this.sql = _sql;
    }

    public JDBCResultSet addSubQuery(String _sql,String logicalName) {
        if (subQueries == null) {
            subQueries = new HashMap<String,JDBCResultSet>();
        }
        JDBCResultSet rs = new JDBCResultSet(_sql);
        this.subQueries.put(logicalName,rs);
        return rs;
{'fraction_non_alphanumeric': 0.10623916811091855, 'fraction_numerical': 0.0076256499133448875, 'mean_word_length': 4.713861386138614, 'pattern_counts': {'":': 0, '<': 45, '<?xml version=': 0, '>': 45, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2411165', 'n_tokens_mistral': 1824, 'n_tokens_neox': 1804, 'n_words': 396}