Search in sources :

Example 1 with MrBeanModule

use of com.fasterxml.jackson.module.mrbean.MrBeanModule in project buck by facebook.

the class BuckEventsHandler method createObjectMapper.

@VisibleForTesting
public static ObjectMapper createObjectMapper() {
    final ObjectMapper objectMapper = new ObjectMapper();
    objectMapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
    objectMapper.registerModule(new MrBeanModule());
    objectMapper.registerModule(new GuavaModule());
    return objectMapper;
}
Also used : MrBeanModule(com.fasterxml.jackson.module.mrbean.MrBeanModule) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) GuavaModule(com.fasterxml.jackson.datatype.guava.GuavaModule) VisibleForTesting(com.google.common.annotations.VisibleForTesting)

Aggregations

ObjectMapper (com.fasterxml.jackson.databind.ObjectMapper)1 GuavaModule (com.fasterxml.jackson.datatype.guava.GuavaModule)1 MrBeanModule (com.fasterxml.jackson.module.mrbean.MrBeanModule)1 VisibleForTesting (com.google.common.annotations.VisibleForTesting)1