@Data
public class ApproveConfigJson implements Serializable {
private String postId;
private boolean hasPreNode = false;
private ApproveConfigJson preNode;
private boolean hasNextNode = false;
private ApproveConfigJson nextNode;
}
json字符串 {"hasNextNode":true,"hasPreNode":false,"jump":true,"nextNode":{"hasNextNode":true,"hasPreNode":true,"jump":true,"nextNode":{"hasNextNode":false,"hasPreNode":true,"jump":true,"passType":1,"postId":"8422e7b960781225747439c620cd0919","preNode":{"$ref":".."},"sort":3},"passType":1,"postId":"1e1e159ad5f8293124208207aa4b76b1","preNode":{"$ref":".."},"sort":2},"passType":1,"postId":"b68aac95774a9682aeddb9a2d15a0c38","preNode":{"hasNextNode":false,"hasPreNode":false,"jump":false,"sort":0},"sort":1}
使用JSON.parseObject(str, ApproveConfigJson.class);方法生成的ApproveConfigJson,在链表第二级节点及之后,无法正确追踪到前一级节点,而这在1.2.78版本是可用的