Sfoglia il codice sorgente

修复敏感数据加解密混合模式SQL注入问题;优化Controller调试日志打印逻辑;

Woody 1 mese fa
parent
commit
66b9bf3d84

+ 1 - 26
framework-base/src/main/java/com/chelvc/framework/base/context/LoggingContextHolder.java

@@ -5,7 +5,6 @@ import java.util.stream.Stream;
 import javax.servlet.ServletRequest;
 import javax.servlet.http.HttpServletRequest;
 
-import ch.qos.logback.classic.Level;
 import com.chelvc.framework.base.util.HttpUtils;
 import com.chelvc.framework.common.model.Platform;
 import com.chelvc.framework.common.model.Terminal;
@@ -121,35 +120,11 @@ public final class LoggingContextHolder {
         }
         buffer.append("]:");
         for (Object message : messages) {
-            if (StringUtils.notEmpty(message)) {
-                buffer.append(" ").append(message);
-            }
+            buffer.append(" ").append(message);
         }
         return buffer.toString();
     }
 
-    /**
-     * 获取日志级别
-     *
-     * @param target 目标对象名称
-     * @return 日志级别
-     */
-    public static Level level(@NonNull String target) {
-        String property = LOGGING_LEVEL_PREFIX + target;
-        String level = ApplicationContextHolder.getProperty(property);
-        return StringUtils.ifEmpty(level, Level::toLevel);
-    }
-
-    /**
-     * 获取日志级别
-     *
-     * @param target 目标对象
-     * @return 日志级别
-     */
-    public static Level level(@NonNull Class<?> target) {
-        return level(target.getName());
-    }
-
     /**
      * 打印正常日志
      *

+ 9 - 12
framework-base/src/main/java/com/chelvc/framework/base/interceptor/ControllerAccessInterceptor.java

@@ -1,15 +1,16 @@
 package com.chelvc.framework.base.interceptor;
 
-import ch.qos.logback.classic.Level;
+import com.chelvc.framework.base.context.ApplicationContextHolder;
 import com.chelvc.framework.base.context.LoggingContextHolder;
 import com.chelvc.framework.base.context.SessionContextHolder;
-import lombok.extern.slf4j.Slf4j;
 import org.aspectj.lang.JoinPoint;
 import org.aspectj.lang.ProceedingJoinPoint;
 import org.aspectj.lang.Signature;
 import org.aspectj.lang.annotation.Around;
 import org.aspectj.lang.annotation.Aspect;
 import org.aspectj.lang.reflect.MethodSignature;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.springframework.boot.web.servlet.error.ErrorController;
 import org.springframework.core.Ordered;
 import org.springframework.core.annotation.Order;
@@ -22,7 +23,6 @@ import org.springframework.web.bind.annotation.ExceptionHandler;
  * @author Woody
  * @date 2024/1/30
  */
-@Slf4j
 @Aspect
 @Component
 @Order(Ordered.HIGHEST_PRECEDENCE)
@@ -35,13 +35,13 @@ public class ControllerAccessInterceptor {
      */
     private boolean isDebug(JoinPoint point) {
         Object target = point.getTarget();
-        if (target instanceof ErrorController) {
+        if (target instanceof ErrorController
+                || !ApplicationContextHolder.getProperty("controller.debug.enabled", boolean.class, false)) {
             return false;
         }
         Signature signature = point.getSignature();
         return signature instanceof MethodSignature
-                && !((MethodSignature) signature).getMethod().isAnnotationPresent(ExceptionHandler.class)
-                && LoggingContextHolder.level(signature.getDeclaringTypeName()) == Level.DEBUG;
+                && !((MethodSignature) signature).getMethod().isAnnotationPresent(ExceptionHandler.class);
     }
 
     /**
@@ -53,13 +53,10 @@ public class ControllerAccessInterceptor {
     @Around("@within(org.springframework.stereotype.Controller) " +
             "|| @within(org.springframework.web.bind.annotation.RestController)")
     public Object logging(ProceedingJoinPoint point) throws Throwable {
-        boolean debug = this.isDebug(point);
-        if (debug) {
-            LoggingContextHolder.debug(log, SessionContextHolder.getRequest(), point.getArgs());
-        }
         Object value = point.proceed();
-        if (debug) {
-            LoggingContextHolder.debug(log, SessionContextHolder.getRequest(), value);
+        if (this.isDebug(point)) {
+            Logger logger = LoggerFactory.getLogger(point.getSignature().getDeclaringTypeName());
+            LoggingContextHolder.debug(logger, SessionContextHolder.getRequest(), value);
         }
         return value;
     }

+ 0 - 42
framework-database/src/main/java/com/chelvc/framework/database/context/TableFieldContext.java

@@ -2,17 +2,11 @@ package com.chelvc.framework.database.context;
 
 import java.io.Serializable;
 import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
-import java.sql.SQLException;
 
 import com.baomidou.mybatisplus.core.metadata.TableFieldInfo;
-import com.chelvc.framework.common.util.ObjectUtils;
 import com.chelvc.framework.database.annotation.Sensitive;
-import com.chelvc.framework.database.handler.SensitiveTypeHandler;
-import com.chelvc.framework.database.sql.WriteStringAcceptor;
 import lombok.Getter;
 import lombok.NonNull;
-import org.apache.ibatis.type.JdbcType;
 import org.apache.ibatis.type.TypeHandler;
 import org.apache.ibatis.type.UnknownTypeHandler;
 
@@ -77,40 +71,4 @@ public class TableFieldContext implements Serializable {
         Class<? extends TypeHandler<?>> type = this.info.getTypeHandler();
         return type == null || type == UnknownTypeHandler.class ? null : DatabaseContextHolder.getTypeHandler(type);
     }
-
-    /**
-     * 处理字段写入值
-     *
-     * @param original 原始值
-     * @return 写入值
-     */
-    @SuppressWarnings("unchecked")
-    public Object handleWriteValue(Object original) {
-        if (original == null) {
-            return null;
-        }
-
-        // 获取TypeHandler实例
-        TypeHandler<?> handler = this.getHandler();
-        if (handler == null || handler instanceof SensitiveTypeHandler) {
-            return original;
-        } else if (this.sensitive) {
-            Class<?> superclass = this.info.getTypeHandler().getSuperclass();
-            int modifiers = superclass.getModifiers();
-            if (Modifier.isAbstract(modifiers) || Modifier.isInterface(modifiers)
-                    || !TypeHandler.class.isAssignableFrom(superclass)) {
-                return original;
-            }
-            handler = DatabaseContextHolder.getTypeHandler((Class<TypeHandler<?>>) superclass);
-        }
-
-        // 接收字符串值写入,如果字符串值不为null则返回字符串值,否则返回原始值
-        WriteStringAcceptor acceptor = new WriteStringAcceptor();
-        try {
-            ((TypeHandler<Object>) handler).setParameter(acceptor, 1, original, JdbcType.OTHER);
-        } catch (SQLException e) {
-            throw new RuntimeException(e);
-        }
-        return ObjectUtils.ifNull(acceptor.getValue(), original);
-    }
 }

+ 43 - 0
framework-database/src/main/java/com/chelvc/framework/database/handler/CryptoTypeHandler.java

@@ -0,0 +1,43 @@
+package com.chelvc.framework.database.handler;
+
+import java.sql.CallableStatement;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+
+import com.chelvc.framework.database.context.DatabaseContextHolder;
+import org.apache.ibatis.type.BaseTypeHandler;
+import org.apache.ibatis.type.JdbcType;
+
+/**
+ * 加解密字段类型处理实现
+ *
+ * @author Woody
+ * @date 2024/6/7
+ */
+public class CryptoTypeHandler extends BaseTypeHandler<String> {
+    @Override
+    public void setNonNullParameter(PreparedStatement ps, int i, String parameter, JdbcType jdbcType)
+            throws SQLException {
+        parameter = DatabaseContextHolder.getDatabaseCipherHandler().encrypt(parameter, true);
+        ps.setString(i, parameter);
+    }
+
+    @Override
+    public String getNullableResult(ResultSet rs, String columnName) throws SQLException {
+        String value = rs.getString(columnName);
+        return DatabaseContextHolder.getDatabaseCipherHandler().decrypt(value, true);
+    }
+
+    @Override
+    public String getNullableResult(ResultSet rs, int columnIndex) throws SQLException {
+        String value = rs.getString(columnIndex);
+        return DatabaseContextHolder.getDatabaseCipherHandler().decrypt(value, true);
+    }
+
+    @Override
+    public String getNullableResult(CallableStatement cs, int columnIndex) throws SQLException {
+        String value = cs.getString(columnIndex);
+        return DatabaseContextHolder.getDatabaseCipherHandler().decrypt(value, true);
+    }
+}

+ 20 - 48
framework-database/src/main/java/com/chelvc/framework/database/interceptor/DynamicInvokeInterceptor.java

@@ -1,8 +1,6 @@
 package com.chelvc.framework.database.interceptor;
 
 import java.sql.Connection;
-import java.time.temporal.Temporal;
-import java.util.Date;
 import java.util.List;
 import java.util.Map;
 import java.util.Objects;
@@ -20,6 +18,7 @@ import com.chelvc.framework.database.entity.Creatable;
 import com.chelvc.framework.database.entity.Deletable;
 import com.chelvc.framework.database.entity.Environmental;
 import com.chelvc.framework.database.entity.Updatable;
+import com.chelvc.framework.database.handler.CryptoTypeHandler;
 import com.google.common.collect.Lists;
 import lombok.RequiredArgsConstructor;
 import net.sf.jsqlparser.JSQLParserException;
@@ -31,7 +30,6 @@ import net.sf.jsqlparser.expression.Function;
 import net.sf.jsqlparser.expression.JdbcParameter;
 import net.sf.jsqlparser.expression.NullValue;
 import net.sf.jsqlparser.expression.Parenthesis;
-import net.sf.jsqlparser.expression.StringValue;
 import net.sf.jsqlparser.expression.operators.conditional.AndExpression;
 import net.sf.jsqlparser.expression.operators.conditional.OrExpression;
 import net.sf.jsqlparser.expression.operators.relational.ComparisonOperator;
@@ -75,6 +73,8 @@ import org.apache.ibatis.plugin.Plugin;
 import org.apache.ibatis.plugin.Signature;
 import org.apache.ibatis.reflection.MetaObject;
 import org.apache.ibatis.reflection.SystemMetaObject;
+import org.apache.ibatis.session.Configuration;
+import org.apache.ibatis.type.StringTypeHandler;
 import org.apache.ibatis.type.TypeHandler;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
@@ -355,41 +355,6 @@ public class DynamicInvokeInterceptor implements Interceptor {
                         Consumer<Expression> changing);
     }
 
-    /**
-     * 判断是否是元类型参数
-     *
-     * @param parameter 参数
-     * @return true/false
-     */
-    private boolean isMetaParameter(Object parameter) {
-        return parameter == null || parameter instanceof Enum || parameter instanceof Number
-                || parameter instanceof String || parameter instanceof Boolean || parameter instanceof Character
-                || parameter instanceof Date || parameter instanceof Temporal;
-    }
-
-    /**
-     * 获取参数值
-     *
-     * @param bound     绑定SQL
-     * @param parameter 参数值表达式
-     * @return 参数值
-     */
-    private Object getParameterValue(BoundSql bound, JdbcParameter parameter) {
-        Object object = bound.getParameterObject();
-        if (this.isMetaParameter(object)) {
-            return object;
-        }
-        List<ParameterMapping> mappings = bound.getParameterMappings();
-        if (ObjectUtils.isEmpty(mappings)) {
-            return null;
-        }
-        String property = mappings.get(parameter.getIndex() - 1).getProperty();
-        if (bound.hasAdditionalParameter(property)) {
-            return bound.getAdditionalParameter(property);
-        }
-        return SystemMetaObject.forObject(object).getValue(property);
-    }
-
     /**
      * 预处理JdbcParameter类型参数,并返回SQL结构是否变更
      *
@@ -846,23 +811,30 @@ public class DynamicInvokeInterceptor implements Interceptor {
             return false;
         }
 
-        // 获取参数明文并添加明文或密文查询条件
-        Object value = context.handleWriteValue(this.getParameterValue(bound, parameter));
-        if (!(value instanceof String)) {
-            return false;
-        } else if (!this.properties.getCrypto().isWritable()) {
-            // 如果未开启加密写入功能,则添加密文查询条件
-            value = DatabaseContextHolder.getDatabaseCipherHandler().encrypt((String) value, true);
+        // 构建混合模式附加参数
+        TypeHandler<?> handler;
+        if (this.properties.getCrypto().isWritable()) {
+            // 明文参数 Handler
+            handler = DatabaseContextHolder.getTypeHandler(StringTypeHandler.class);
+        } else {
+            // 加密参数 Handler
+            handler = DatabaseContextHolder.getTypeHandler(CryptoTypeHandler.class);
         }
-        StringValue target = new StringValue((String) value);
+        List<ParameterMapping> mappings = bound.getParameterMappings();
+        String property = mappings.get(parameter.getIndex() - 1).getProperty();
+        Configuration configuration = DatabaseContextHolder.getSessionTemplate().getConfiguration();
+        mappings.add(new ParameterMapping.Builder(configuration, property, handler).build());
+        JdbcParameter extra = new JdbcParameter(mappings.size(), parameter.isUseFixedIndex());
+
+        // 将附附加参数添加到当前SQL
         if (condition instanceof InExpression) {
             InExpression in = (InExpression) condition;
-            ((ExpressionList) in.getRightItemsList()).getExpressions().add(target);
+            ((ExpressionList) in.getRightItemsList()).getExpressions().add(extra);
         } else {
             ComparisonOperator comparison = (ComparisonOperator) condition;
             Expression left = comparison.getLeftExpression(), right = comparison.getRightExpression();
             Column _column = left instanceof Column ? (Column) left : (Column) right;
-            InExpression in = new InExpression(_column, new ExpressionList(parameter, target));
+            InExpression in = new InExpression(_column, new ExpressionList(parameter, extra));
             in.setNot(condition instanceof NotEqualsTo);
             changing.accept(in);
         }

+ 0 - 1093
framework-database/src/main/java/com/chelvc/framework/database/sql/MinimumCallableStatement.java

@@ -1,1093 +0,0 @@
-package com.chelvc.framework.database.sql;
-
-import java.io.InputStream;
-import java.io.Reader;
-import java.math.BigDecimal;
-import java.net.URL;
-import java.sql.Array;
-import java.sql.Blob;
-import java.sql.CallableStatement;
-import java.sql.Clob;
-import java.sql.Connection;
-import java.sql.Date;
-import java.sql.NClob;
-import java.sql.ParameterMetaData;
-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.Time;
-import java.sql.Timestamp;
-import java.util.Calendar;
-import java.util.Map;
-
-/**
- * CallableStatement最小实现
- *
- * @author Woody
- * @date 2024/6/8
- */
-public interface MinimumCallableStatement extends CallableStatement {
-    @Override
-    default void registerOutParameter(int parameterIndex, int sqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void registerOutParameter(int parameterIndex, int sqlType, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean wasNull() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getString(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getBoolean(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte getByte(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default short getShort(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getInt(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default long getLong(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default float getFloat(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default double getDouble(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(int parameterIndex, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte[] getBytes(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(int parameterIndex, Map<String, Class<?>> map) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Ref getRef(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Blob getBlob(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Clob getClob(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Array getArray(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(int parameterIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(int parameterIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(int parameterIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void registerOutParameter(int parameterIndex, int sqlType, String typeName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void registerOutParameter(String parameterName, int sqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void registerOutParameter(String parameterName, int sqlType, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void registerOutParameter(String parameterName, int sqlType, String typeName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default URL getURL(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setURL(String parameterName, URL val) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(String parameterName, int sqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBoolean(String parameterName, boolean x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setByte(String parameterName, byte x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setShort(String parameterName, short x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setInt(String parameterName, int x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setLong(String parameterName, long x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFloat(String parameterName, float x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDouble(String parameterName, double x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBigDecimal(String parameterName, BigDecimal x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setString(String parameterName, String x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBytes(String parameterName, byte[] x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(String parameterName, Date x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(String parameterName, Time x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(String parameterName, Timestamp x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(String parameterName, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(String parameterName, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(String parameterName, Object x, int targetSqlType, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(String parameterName, Object x, int targetSqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(String parameterName, Object x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(String parameterName, Reader reader, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(String parameterName, Date x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(String parameterName, Time x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(String parameterName, Timestamp x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(String parameterName, int sqlType, String typeName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getString(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getBoolean(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte getByte(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default short getShort(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getInt(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default long getLong(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default float getFloat(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default double getDouble(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte[] getBytes(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(String parameterName, Map<String, Class<?>> map) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Ref getRef(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Blob getBlob(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Clob getClob(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Array getArray(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(String parameterName, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(String parameterName, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(String parameterName, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default URL getURL(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default RowId getRowId(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default RowId getRowId(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setRowId(String parameterName, RowId x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNString(String parameterName, String value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(String parameterName, Reader value, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(String parameterName, NClob value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(String parameterName, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(String parameterName, InputStream inputStream, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(String parameterName, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default NClob getNClob(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default NClob getNClob(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setSQLXML(String parameterName, SQLXML xmlObject) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLXML getSQLXML(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLXML getSQLXML(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getNString(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getNString(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getNCharacterStream(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getNCharacterStream(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getCharacterStream(int parameterIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getCharacterStream(String parameterName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(String parameterName, Blob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(String parameterName, Clob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(String parameterName, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(String parameterName, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(String parameterName, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(String parameterName, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(String parameterName, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(String parameterName, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(String parameterName, Reader value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(String parameterName, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(String parameterName, InputStream inputStream) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(String parameterName, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T getObject(int parameterIndex, Class<T> type) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T getObject(String parameterName, Class<T> type) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet executeQuery() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(int parameterIndex, int sqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBoolean(int parameterIndex, boolean x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setByte(int parameterIndex, byte x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setShort(int parameterIndex, short x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setInt(int parameterIndex, int x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setLong(int parameterIndex, long x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFloat(int parameterIndex, float x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDouble(int parameterIndex, double x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBigDecimal(int parameterIndex, BigDecimal x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setString(int parameterIndex, String x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBytes(int parameterIndex, byte[] x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(int parameterIndex, Date x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(int parameterIndex, Time x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(int parameterIndex, Timestamp x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setUnicodeStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearParameters() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x, int targetSqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void addBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setRef(int parameterIndex, Ref x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, Blob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Clob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setArray(int parameterIndex, Array x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSetMetaData getMetaData() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(int parameterIndex, Date x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(int parameterIndex, Time x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(int parameterIndex, Timestamp x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(int parameterIndex, int sqlType, String typeName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setURL(int parameterIndex, URL x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ParameterMetaData getParameterMetaData() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setRowId(int parameterIndex, RowId x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNString(int parameterIndex, String value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(int parameterIndex, Reader value, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, NClob value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, InputStream inputStream, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x, int targetSqlType, int scaleOrLength) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(int parameterIndex, Reader value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, InputStream inputStream) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet executeQuery(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void close() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getMaxFieldSize() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setMaxFieldSize(int max) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getMaxRows() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setMaxRows(int max) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setEscapeProcessing(boolean enable) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getQueryTimeout() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setQueryTimeout(int seconds) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void cancel() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLWarning getWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCursorName(String name) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet getResultSet() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getUpdateCount() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getMoreResults() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchDirection(int direction) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchDirection() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchSize(int rows) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchSize() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetConcurrency() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetType() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void addBatch(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int[] executeBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Connection getConnection() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getMoreResults(int current) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet getGeneratedKeys() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, int autoGeneratedKeys) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, int[] columnIndexes) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, String[] columnNames) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, int autoGeneratedKeys) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, int[] columnIndexes) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, String[] columnNames) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetHoldability() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isClosed() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setPoolable(boolean poolable) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isPoolable() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void closeOnCompletion() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isCloseOnCompletion() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T unwrap(Class<T> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isWrapperFor(Class<?> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-}

+ 0 - 527
framework-database/src/main/java/com/chelvc/framework/database/sql/MinimumPreparedStatement.java

@@ -1,527 +0,0 @@
-package com.chelvc.framework.database.sql;
-
-import java.io.InputStream;
-import java.io.Reader;
-import java.math.BigDecimal;
-import java.net.URL;
-import java.sql.Array;
-import java.sql.Blob;
-import java.sql.Clob;
-import java.sql.Connection;
-import java.sql.Date;
-import java.sql.NClob;
-import java.sql.ParameterMetaData;
-import java.sql.PreparedStatement;
-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.Time;
-import java.sql.Timestamp;
-import java.util.Calendar;
-
-/**
- * PreparedStatement最小实现
- *
- * @author Woody
- * @date 2024/6/8
- */
-public interface MinimumPreparedStatement extends PreparedStatement {
-    @Override
-    default ResultSet executeQuery() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(int parameterIndex, int sqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBoolean(int parameterIndex, boolean x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setByte(int parameterIndex, byte x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setShort(int parameterIndex, short x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setInt(int parameterIndex, int x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setLong(int parameterIndex, long x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFloat(int parameterIndex, float x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDouble(int parameterIndex, double x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBigDecimal(int parameterIndex, BigDecimal x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setString(int parameterIndex, String x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBytes(int parameterIndex, byte[] x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(int parameterIndex, Date x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(int parameterIndex, Time x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(int parameterIndex, Timestamp x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setUnicodeStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearParameters() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x, int targetSqlType) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void addBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setRef(int parameterIndex, Ref x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, Blob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Clob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setArray(int parameterIndex, Array x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSetMetaData getMetaData() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setDate(int parameterIndex, Date x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTime(int parameterIndex, Time x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setTimestamp(int parameterIndex, Timestamp x, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNull(int parameterIndex, int sqlType, String typeName) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setURL(int parameterIndex, URL x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ParameterMetaData getParameterMetaData() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setRowId(int parameterIndex, RowId x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNString(int parameterIndex, String value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(int parameterIndex, Reader value, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, NClob value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, InputStream inputStream, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setObject(int parameterIndex, Object x, int targetSqlType, int scaleOrLength) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setAsciiStream(int parameterIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBinaryStream(int parameterIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCharacterStream(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNCharacterStream(int parameterIndex, Reader value) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setClob(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setBlob(int parameterIndex, InputStream inputStream) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setNClob(int parameterIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet executeQuery(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void close() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getMaxFieldSize() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setMaxFieldSize(int max) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getMaxRows() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setMaxRows(int max) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setEscapeProcessing(boolean enable) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getQueryTimeout() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setQueryTimeout(int seconds) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void cancel() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLWarning getWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setCursorName(String name) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet getResultSet() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getUpdateCount() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getMoreResults() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchDirection(int direction) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchDirection() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchSize(int rows) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchSize() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetConcurrency() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetType() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void addBatch(String sql) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int[] executeBatch() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Connection getConnection() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getMoreResults(int current) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSet getGeneratedKeys() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, int autoGeneratedKeys) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, int[] columnIndexes) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int executeUpdate(String sql, String[] columnNames) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, int autoGeneratedKeys) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, int[] columnIndexes) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean execute(String sql, String[] columnNames) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getResultSetHoldability() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isClosed() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setPoolable(boolean poolable) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isPoolable() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void closeOnCompletion() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isCloseOnCompletion() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T unwrap(Class<T> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isWrapperFor(Class<?> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-}

+ 0 - 986
framework-database/src/main/java/com/chelvc/framework/database/sql/MinimumResultSet.java

@@ -1,986 +0,0 @@
-package com.chelvc.framework.database.sql;
-
-import java.io.InputStream;
-import java.io.Reader;
-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.Calendar;
-import java.util.Map;
-
-/**
- * ResultSet最小实现
- *
- * @author Woody
- * @date 2024/6/8
- */
-public interface MinimumResultSet extends ResultSet {
-    @Override
-    default boolean next() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void close() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean wasNull() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getString(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getBoolean(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte getByte(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default short getShort(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getInt(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default long getLong(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default float getFloat(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default double getDouble(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte[] getBytes(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getAsciiStream(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getUnicodeStream(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getBinaryStream(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getString(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean getBoolean(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte getByte(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default short getShort(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getInt(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default long getLong(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default float getFloat(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default double getDouble(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default byte[] getBytes(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getAsciiStream(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getUnicodeStream(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default InputStream getBinaryStream(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLWarning getWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void clearWarnings() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getCursorName() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default ResultSetMetaData getMetaData() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int findColumn(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getCharacterStream(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getCharacterStream(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default BigDecimal getBigDecimal(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isBeforeFirst() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isAfterLast() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isFirst() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isLast() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void beforeFirst() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void afterLast() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean first() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean last() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean absolute(int row) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean relative(int rows) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean previous() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchDirection(int direction) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchDirection() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void setFetchSize(int rows) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getFetchSize() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getType() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getConcurrency() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean rowUpdated() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean rowInserted() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean rowDeleted() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNull(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBoolean(int columnIndex, boolean x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateByte(int columnIndex, byte x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateShort(int columnIndex, short x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateInt(int columnIndex, int x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateLong(int columnIndex, long x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateFloat(int columnIndex, float x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateDouble(int columnIndex, double x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBigDecimal(int columnIndex, BigDecimal x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateString(int columnIndex, String x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBytes(int columnIndex, byte[] x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateDate(int columnIndex, Date x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateTime(int columnIndex, Time x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateTimestamp(int columnIndex, Timestamp x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(int columnIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(int columnIndex, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(int columnIndex, Reader x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateObject(int columnIndex, Object x, int scaleOrLength) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateObject(int columnIndex, Object x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNull(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBoolean(String columnLabel, boolean x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateByte(String columnLabel, byte x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateShort(String columnLabel, short x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateInt(String columnLabel, int x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateLong(String columnLabel, long x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateFloat(String columnLabel, float x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateDouble(String columnLabel, double x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBigDecimal(String columnLabel, BigDecimal x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateString(String columnLabel, String x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBytes(String columnLabel, byte[] x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateDate(String columnLabel, Date x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateTime(String columnLabel, Time x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateTimestamp(String columnLabel, Timestamp x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(String columnLabel, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(String columnLabel, InputStream x, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(String columnLabel, Reader reader, int length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateObject(String columnLabel, Object x, int scaleOrLength) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateObject(String columnLabel, Object x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void insertRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void deleteRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void refreshRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void cancelRowUpdates() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void moveToInsertRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void moveToCurrentRow() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Statement getStatement() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(int columnIndex, Map<String, Class<?>> map) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Ref getRef(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Blob getBlob(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Clob getClob(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Array getArray(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Object getObject(String columnLabel, Map<String, Class<?>> map) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Ref getRef(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Blob getBlob(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Clob getClob(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Array getArray(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(int columnIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Date getDate(String columnLabel, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(int columnIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Time getTime(String columnLabel, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(int columnIndex, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Timestamp getTimestamp(String columnLabel, Calendar cal) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default URL getURL(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default URL getURL(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateRef(int columnIndex, Ref x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateRef(String columnLabel, Ref x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(int columnIndex, Blob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(String columnLabel, Blob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(int columnIndex, Clob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(String columnLabel, Clob x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateArray(int columnIndex, Array x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateArray(String columnLabel, Array x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default RowId getRowId(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default RowId getRowId(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateRowId(int columnIndex, RowId x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateRowId(String columnLabel, RowId x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default int getHoldability() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isClosed() throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNString(int columnIndex, String nString) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNString(String columnLabel, String nString) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(int columnIndex, NClob nClob) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(String columnLabel, NClob nClob) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default NClob getNClob(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default NClob getNClob(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLXML getSQLXML(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default SQLXML getSQLXML(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateSQLXML(int columnIndex, SQLXML xmlObject) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateSQLXML(String columnLabel, SQLXML xmlObject) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getNString(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default String getNString(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getNCharacterStream(int columnIndex) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default Reader getNCharacterStream(String columnLabel) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNCharacterStream(int columnIndex, Reader x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNCharacterStream(String columnLabel, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(int columnIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(int columnIndex, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(int columnIndex, Reader x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(String columnLabel, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(String columnLabel, InputStream x, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(String columnLabel, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(int columnIndex, InputStream inputStream, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(String columnLabel, InputStream inputStream, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(int columnIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(String columnLabel, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(int columnIndex, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(String columnLabel, Reader reader, long length) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNCharacterStream(int columnIndex, Reader x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNCharacterStream(String columnLabel, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(int columnIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(int columnIndex, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(int columnIndex, Reader x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateAsciiStream(String columnLabel, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBinaryStream(String columnLabel, InputStream x) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateCharacterStream(String columnLabel, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(int columnIndex, InputStream inputStream) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateBlob(String columnLabel, InputStream inputStream) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(int columnIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateClob(String columnLabel, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(int columnIndex, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default void updateNClob(String columnLabel, Reader reader) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T getObject(int columnIndex, Class<T> type) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T getObject(String columnLabel, Class<T> type) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default <T> T unwrap(Class<T> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-
-    @Override
-    default boolean isWrapperFor(Class<?> iface) throws SQLException {
-        throw new UnsupportedOperationException();
-    }
-}

+ 0 - 57
framework-database/src/main/java/com/chelvc/framework/database/sql/WriteStringAcceptor.java

@@ -1,57 +0,0 @@
-package com.chelvc.framework.database.sql;
-
-import java.sql.SQLException;
-import java.sql.SQLType;
-
-import lombok.Getter;
-
-/**
- * 字符串数据写入接收器
- *
- * @author Woody
- * @date 2024/6/11
- */
-@Getter
-public class WriteStringAcceptor implements MinimumPreparedStatement {
-    private String value;
-
-    @Override
-    public void setObject(int parameterIndex, Object x) throws SQLException {
-        if (x instanceof String) {
-            this.setString(parameterIndex, (String) x);
-        }
-    }
-
-    @Override
-    public void setObject(int parameterIndex, Object x, int targetSqlType) throws SQLException {
-        if (x instanceof String) {
-            this.setString(parameterIndex, (String) x);
-        }
-    }
-
-    @Override
-    public void setObject(int parameterIndex, Object x, int targetSqlType, int scaleOrLength) throws SQLException {
-        if (x instanceof String) {
-            this.setString(parameterIndex, (String) x);
-        }
-    }
-
-    @Override
-    public void setObject(int parameterIndex, Object x, SQLType targetSqlType) throws SQLException {
-        if (x instanceof String) {
-            this.setString(parameterIndex, (String) x);
-        }
-    }
-
-    @Override
-    public void setObject(int parameterIndex, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException {
-        if (x instanceof String) {
-            this.setString(parameterIndex, (String) x);
-        }
-    }
-
-    @Override
-    public void setString(int parameterIndex, String x) throws SQLException {
-        this.value = x;
-    }
-}