공부
[ObjectMapper] How do I disable fail_on_empty_beans in Jackson? mapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false);
승가비
2022. 6. 20. 00:40
728x90
ObjectMapper mapper = new ObjectMapper();
mapper.configure(SerializationFeature.FAIL_ON_EMPTY_BEANS, false);
// do various things, perhaps:
String someJsonString = mapper.writeValueAsString(someClassInstance);
SomeClass someClassInstance = mapper.readValue(someJsonString, SomeClass.class)
https://stackoverflow.com/questions/15261456/how-do-i-disable-fail-on-empty-beans-in-jackson
How do I disable fail_on_empty_beans in Jackson?
Using jackson 2.1, how do I disable the fail_on_empty beans that the error message seems to want me to disable? I'm assuming this is just the simplest thing in the world, but hell it is late and I
stackoverflow.com
728x90