Self referencing loop in Json.Net JsonSerializer from custom JsonConverter (Web API)

前端 未结 7 1243
温柔的废话
温柔的废话 2020-12-16 09:28

The project is an Asp.Net Web API web service.

I have a type hierarchy that I need to be able to serialize to and from Json, so I have taken the code from this SO: H

相关标签:
7条回答
  • 2020-12-16 10:00

    This might help someone, but in my case I was trying to override the Equals method to have my object be treated as value type. In my research, I found that JSON.NET doesn't like this:

    JSON.NET Self Referencing Error

    0 讨论(0)
提交回复
热议问题