Jackson JSON serialization, recursion avoidance by level defining

前端 未结 7 1342
庸人自扰
庸人自扰 2020-12-02 20:46

I use Jackson library for serialization of my pojo objects into JSON representation. For example I have class A and class B:

class A {
  privat         


        
7条回答
  •  南笙
    南笙 (楼主)
    2020-12-02 21:01

    For some cases you can limit serialization depth using a thread local integer holding max depth. See this answer.

提交回复
热议问题