概述 今天遇见一个需求,需要对json数据进行下划线与驼峰格式之间进行转换,在Fastjson.Jackson.Gson都提供了转换的方式,在这里进行一下列举. User类: public class User { private String nameInfo; private String ageInfo; public String getNameInfo() { return nameInfo; } public void setNameInfo(String nameInfo) { t
用法 int x1 = 2_014; // Underscore in deciaml format int x2 = 2___014; // Multiple consecutive underscores int x3 = 02_014; // Underscore in octal literal int x4 = 0b0111_1011_0001; // Underscore in binary literal int x5 = 0x7_B_1; // Underscores in he
实体类: import java.io.Serializable; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; @Data @AllArgsConstructor @NoArgsConstructor public class User implements Serializable { /** * */ private static final long seria
为什么 由于工作是做数据ETL的,很多时候会使用到正则对数据进行提取,但是java的正则中的groupname不支持'_',官方的文档中是这样的: Group name A capturing group can also be assigned a "name", a named-capturing group, and then be back-referenced later by the "name". Group names are composed of