Package com.broadleafcommerce.rest.api
Class WrapperOverrideTypeModifier
java.lang.Object
com.fasterxml.jackson.databind.type.TypeModifier
com.broadleafcommerce.rest.api.WrapperOverrideTypeModifier
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.context.ApplicationContextAware
public class WrapperOverrideTypeModifier
extends com.fasterxml.jackson.databind.type.TypeModifier
implements org.springframework.context.ApplicationContextAware
Provides an implementation of a
TypeModifier that looks up types in the application context for wrapper overrides.
This allows for correct instantiation to occur when wrappers have been overridden and a client is actually sending JSON- Author:
- Phillip Verheyden (phillipuniverse)
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.springframework.context.ApplicationContext -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.fasterxml.jackson.databind.JavaTypemodifyType(com.fasterxml.jackson.databind.JavaType type, Type jdkType, com.fasterxml.jackson.databind.type.TypeBindings context, com.fasterxml.jackson.databind.type.TypeFactory typeFactory) voidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext)
-
Field Details
-
applicationContext
protected org.springframework.context.ApplicationContext applicationContext
-
-
Constructor Details
-
WrapperOverrideTypeModifier
public WrapperOverrideTypeModifier()
-
-
Method Details
-
modifyType
public com.fasterxml.jackson.databind.JavaType modifyType(com.fasterxml.jackson.databind.JavaType type, Type jdkType, com.fasterxml.jackson.databind.type.TypeBindings context, com.fasterxml.jackson.databind.type.TypeFactory typeFactory) - Specified by:
modifyTypein classcom.fasterxml.jackson.databind.type.TypeModifier
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException - Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware- Throws:
org.springframework.beans.BeansException
-