All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.rrsunhome.excelsql.config.SqlParameterIndexValue Maven / Gradle / Ivy

There is a newer version: 2.1.2
Show newest version
package com.github.rrsunhome.excelsql.config;

import com.github.rrsunhome.excelsql.util.SqlUtils;
import lombok.Getter;

/**
 * @author : wangqijia
 * create at:  2021/11/7  下午10:44
 */
@Getter
public class SqlParameterIndexValue {

    private int cellIndex;

    private Class valueType;

    public SqlParameterIndexValue(int cellIndex, Class valueType) {
        this.cellIndex = cellIndex;
        this.valueType = valueType;
    }

    public String wrapValue(String value) {
        if (String.class.equals(valueType)) {
            return SqlUtils.specialChars(value);
        }
        return value;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy