public static ObjectMapper getDefaultObjectMapper ( ) { ObjectMapper mapper = new ObjectMapper ( ) ; mapper . configure ( DeserializationFeature . FAIL_ON_UNKNOWN_PROPERTIES , false ) ; mapper . configure ( DeserializationFeature . READ_UNKNOWN_ENUM_VALUES_AS_NULL , true ) ; mapper . configure ( SerializationFeature . FAIL_ON_EMPTY_BEANS , false ) ; mapper . setSerializationInclusion ( JsonInclude . Include . NON_NULL ) ; return mapper ; }
Gets default object mapper .