
cn.cucc.bean.Update Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jpaHelper Show documentation
Show all versions of jpaHelper Show documentation
spring-data-jpa增强工具包,简化 CRUD 操作
package cn.cucc.bean;
import java.util.HashMap;
import java.util.Map;
import cn.cucc.reflection.ReflectionUtil;
import cn.cucc.reflection.SerializableFunction;
public class Update {
Map sets;
public Update() {
sets = new HashMap();
}
public Update set(String key, Object value) {
sets.put(key, value);
return this;
}
public Update set(SerializableFunction property, Object value) {
sets.put(ReflectionUtil.getFieldName(property), value);
return this;
}
public Map getSets() {
return sets;
}
public void setSets(Map sets) {
this.sets = sets;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy