各种转化
//对象转化为json
UserInfo userInfo=new UserInfo();
userInfo.setName("lisi");
userInfo.setUserId("2");
ObjectMapper mapper = new ObjectMapper();
ObjectWriter ow = mapper.writer().withDefaultPrettyPrinter();
String json=ow.writeValueAsString(userInfo);
along