49,自增长序列id'

@Id
@GeneratedValue(strategy = GenerationType.IDENTITY) //自增长序列

2, json字符串转json对象

String result=“{"code":"10000","charge":false,"msg":"查询成功",
"result":{"desc":"查询成功","status":0,"result":{"seller":"电信","area":"浙江省杭州市"} }} ”;

 MessageModel messageModel = JSON.parseObject(result, MessageModel.class);//json字符串转json对象

        statusModel statusmodel=JSON.parseObject(messageModel.getResult(),statusModel.class); //json字符串转json对象

  AreaModel areaModel=JSON.parseObject(statusmodel.getResult(),AreaModel.class); //json字符串转model 解析内容

        System.out.println("ip来源于:"+areaModel.getArea()); //json字符串转model 解析内容

你可能感兴趣的:(49,自增长序列id')