refactor sql parser.

This commit is contained in:
wenshao
2017-09-18 11:25:40 +08:00
parent 3c98a1eee5
commit 8343ca08c4
29 changed files with 201 additions and 499 deletions
@@ -46,12 +46,11 @@ import com.alibaba.druid.proxy.jdbc.JdbcParameter.TYPE;
* @author wenshao [szujobs@hotmail.com]
*/
public class PreparedStatementProxyImpl extends StatementProxyImpl implements PreparedStatementProxy {
private PreparedStatement statement;
protected final String sql;
private JdbcParameter[] parameters;
private int parametersSize = 0;
private Map<Integer, JdbcParameter> paramMap = null;
private PreparedStatement statement;
protected final String sql;
private JdbcParameter[] parameters;
private int parametersSize;
private Map<Integer, JdbcParameter> paramMap;
public PreparedStatementProxyImpl(ConnectionProxy connection, PreparedStatement statement, String sql, long id){
super(connection, statement, id);
@@ -34,23 +34,17 @@ import com.alibaba.druid.stat.JdbcSqlStat;
*/
public class StatementProxyImpl extends WrapperProxyImpl implements StatementProxy {
private final ConnectionProxy connection;
protected Statement statement;
protected String lastExecuteSql;
protected long lastExecuteStartNano;
protected long lastExecuteTimeNano;
protected JdbcSqlStat sqlStat;
protected boolean firstResultSet;
protected ArrayList<String> batchSqlList;
protected StatementExecuteType lastExecuteType;
protected Integer updateCount = null;
private FilterChainImpl filterChain = null;
private final ConnectionProxy connection;
protected Statement statement;
protected String lastExecuteSql;
protected long lastExecuteStartNano;
protected long lastExecuteTimeNano;
protected JdbcSqlStat sqlStat;
protected boolean firstResultSet;
protected ArrayList<String> batchSqlList;
protected StatementExecuteType lastExecuteType;
protected Integer updateCount;
private FilterChainImpl filterChain;
public StatementProxyImpl(ConnectionProxy connection, Statement statement, long id){
super(statement, id);