cn.sylinx.hbatis.db.dialect.DefaultDialect Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of hbatis-core Show documentation
Show all versions of hbatis-core Show documentation
hbatis is a simple orm framework
package cn.sylinx.hbatis.db.dialect;
import java.sql.CallableStatement;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.List;
import cn.sylinx.hbatis.db.common.FS;
import cn.sylinx.hbatis.db.dialect.sql.SqlBuilder;
import cn.sylinx.hbatis.db.dialect.sql.SqlBuilderFactory;
import cn.sylinx.hbatis.type.TypeHandler;
import cn.sylinx.hbatis.type.TypeHandlerRegistry;
@SuppressWarnings("unchecked")
public abstract class DefaultDialect implements Dialect {
@Override
public void setParameters(PreparedStatement pst, Object... params) throws SQLException {
for (int i = 0, size = params.length; i < size; i++) {
setParameter(pst, i + 1, params[i]);
}
}
protected void setParameter(PreparedStatement pst, int index, Object param) throws SQLException {
TypeHandler