import org.apache.commons.beanutils.BeanUtils;

 

public static Map<String, Object> toReplaceKeyLow(Map<String, Object> map) {
        Map re_map = new HashMap();
        if(re_map != null) {
            Iterator var2 = map.entrySet().iterator();

            while(var2.hasNext()) {
                Entry<String, Object> entry = (Entry)var2.next();
                re_map.put(underlineToCamel((String)entry.getKey()), map.get(entry.getKey()));
            }

            map.clear();
        }

        return re_map;
    }

MAP 调用 toReplaceKeyLow 方法

//将获取到的Map值转换成驼峰命名法
        Map bankMap = CommTool.toReplaceKeyLow(toobtain);

//将MAP转换成实体
                        PreTiedCardBo preTiedCardBo = new PreTiedCardBo();
                        BeanUtils.populate(preTiedCardBo, bankMap);    

  

相关文章:

  • 2021-09-26
  • 2022-12-23
  • 2021-08-05
  • 2022-12-23
  • 2022-03-01
  • 2021-05-26
  • 2022-12-23
  • 2021-10-28
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-02-25
  • 2022-12-23
相关资源
相似解决方案