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

top.cutexingluo.tools.designtools.json.serializer.pkg.sensitive.SensitiveSerializer Maven / Gradle / Ivy

Go to download

xingtools 依赖core,附加,也就是基于 SpringBoot 的一些工具或实体类

There is a newer version: 1.1.6
Show newest version
package top.cutexingluo.tools.designtools.json.serializer.pkg.sensitive;

import top.cutexingluo.tools.designtools.json.serializer.StrJsonStrategy;

/**
 * 敏感过滤器
 *
 * @author XingTian
 * @version 1.0.0
 * @date 2024/1/1 15:37
 * @since 1.0.4
 */
public class SensitiveSerializer implements StrJsonStrategy {

    private final StrJsonStrategy desensitize;

    public SensitiveSerializer() {
        this("");
    }

    public SensitiveSerializer(String name) {
        desensitize = SensitiveStrategy.getStrategy(name).desensitize();
    }

    @Override
    public String toJsonStr(String originStr) {
        return desensitize.toJsonStr(originStr);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy