.Net serialize object to custom JSON (sort of) format
This question already has an answer here:
Not the most graceful way to do it, but you could always consider using JSON.NET, serializing your object to a JSON string, then performing string manipulation on the output to get it into the format you desire. I'm sure you could write up a quick method that will take in a JSON string and spit it out in a REST service compatible format. That way you don't exactly have to write your own serializer.
链接地址: http://www.djcxy.com/p/14216.html上一篇: 针对json字符串python运行测试