Package com.aevans.test.web

Source Code of com.aevans.test.web.EndpointResponseObjectMapper

package com.aevans.test.web;

import org.codehaus.jackson.Version;
import org.codehaus.jackson.map.ObjectMapper;
import org.codehaus.jackson.map.SerializationConfig.Feature;
import org.codehaus.jackson.map.module.SimpleModule;

public class EndpointResponseObjectMapper extends ObjectMapper {

  public EndpointResponseObjectMapper() {
    SimpleModule simpleModule = new SimpleModule("SimpleModule",
              new Version(1,0,0,null));
   
    simpleModule.addSerializer(EndpointResponse.class, new EndpointResponseSerializer());
    registerModule(simpleModule);
    configure(Feature.INDENT_OUTPUT, true);
  }
}
TOP

Related Classes of com.aevans.test.web.EndpointResponseObjectMapper

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.