<dependency> <groupId>com.alibaba</groupId> <artifactId>fastjson</artifactId> <version>1.2.71</version> </dependency>
import com.alibaba.fastjson.JSONObject;
import com.alibaba.fastjson.serializer.SerializerFeature;
String s = JSONObject.toJSONString(对象,SerializerFeature.WriteMapNullValue);
标签:fastjson,对象,JSONObject,alibaba,空值,import,SerializerFeature,com
From: https://www.cnblogs.com/niuniu0108/p/16778747.html