Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package com.fasterxml.jackson.module.afterburner;
 
 
 
 public class AfterburnerModule extends SimpleModule
    // TODO: externalize
    private final static Version VERSION = new Version(1, 8, 0, null);
    /*
    /********************************************************************** 
    /* Configuration settings
    /********************************************************************** 
     */

    
Flag to indicate whether we will try to load generated classes using same class loader as one that loaded class being accessed or not. If not, we will use class loader that loaded this module. Benefit of using value class loader is that 'protected' and 'package access' properties can be accessed; otherwise only 'public' properties can be accessed.

By default this feature is enabled.

    protected boolean _cfgUseValueClassLoader = true;

    
Flag to indicate whether we should use an optimized sub-class of org.codehaus.jackson.map.deser.BeanDeserializer or not. Use of optimized version should further improve performance, but it can be disabled in case it causes issues.

By default this feature is enabled.

    protected boolean _cfgUseOptimizedBeanDeserializer = true;
    
    /*
    /********************************************************************** 
    /* Basic life-cycle
    /********************************************************************** 
     */
    
    public AfterburnerModule()
    {
        super("Afterburner");
    }
    
    @Override
    public void setupModule(SetupContext context)
    {
        super.setupModule(context);
        ClassLoader cl =  ? null : getClass().getClassLoader();
        context.addBeanDeserializerModifier(new DeserializerModifier(cl,
                ));
        context.addBeanSerializerModifier(new SerializerModifier(cl));
    }
    /*
    /********************************************************************** 
    /* Config methods
    /********************************************************************** 
     */

    
Flag to indicate whether we will try to load generated classes using same class loader as one that loaded class being accessed or not. If not, we will use class loader that loaded this module. Benefit of using value class loader is that 'protected' and 'package access' properties can be accessed; otherwise only 'public' properties can be accessed.

By default this feature is enabled.

    public AfterburnerModule setUseValueClassLoader(boolean state) {
         = state;
        return this;
    }
    public AfterburnerModule setUseOptimizedBeanDeserializer(boolean state) {
         = state;
        return this;
    }
New to GrepCode? Check out our FAQ X