Example usage for com.fasterxml.jackson.datatype.hibernate4 Hibernate4Module configure

List of usage examples for com.fasterxml.jackson.datatype.hibernate4 Hibernate4Module configure

Introduction

In this page you can find the example usage for com.fasterxml.jackson.datatype.hibernate4 Hibernate4Module configure.

Prototype

public Hibernate4Module configure(Feature f, boolean state) 

Source Link

Usage

From source file:org.reqlist.arch.HibernateAwareObjectMapper.java

public HibernateAwareObjectMapper() {
    Hibernate4Module hibernate4Module = new Hibernate4Module();

    hibernate4Module.configure(Hibernate4Module.Feature.USE_TRANSIENT_ANNOTATION, false);

    configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);

    registerModule(hibernate4Module);/*from   w  w w .j av  a2s. c o  m*/
}

From source file:org.yamj.core.hibernate.HibernateAwareObjectMapper.java

public HibernateAwareObjectMapper() {
    // https://github.com/FasterXML/jackson-module-hibernate
    Hibernate4Module hm = new Hibernate4Module();
    registerModule(hm);/*from w  w w . ja va  2  s . co  m*/
    hm.configure(Hibernate4Module.Feature.FORCE_LAZY_LOADING, true);

    // https://github.com/FasterXML/jackson-datatype-joda
    registerModule(new JodaModule());
}