在序列化时,我们可以通过设置SerializationFeature来控制是否显示null值。 importcom.fasterxml.jackson.databind.ObjectMapper;importcom.fasterxml.jackson.databind.SerializationFeature;publicclassMain{publicstaticvoidmain(String[]args)throwsException{ObjectMappermapper=newObjectMapper();mapper.configure(SerializationFeature.FAIL...