All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.mozu.api.utils.JsonUtils Maven / Gradle / Ivy

Go to download

Mozu Java is a SDK that enables you to create robust Java applications that integrate with the Mozu platform

There is a newer version: 2.6.1-RC1
Show newest version
package com.mozu.api.utils;

import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.datatype.joda.JodaModule;

public class JsonUtils {
    static public ObjectMapper initObjectMapper() {
        ObjectMapper objectMapper = new ObjectMapper();
        objectMapper.registerModule(new JodaModule());
        objectMapper.configure(com.fasterxml.jackson.databind.SerializationFeature.
            WRITE_DATES_AS_TIMESTAMPS , false);
        objectMapper.disable(DeserializationFeature.FAIL_ON_NULL_FOR_PRIMITIVES);
        return objectMapper;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy