@ConfigurationProperties(value="jackson") public class JacksonConfiguration extends Object
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_ARRAYSIZETHRESHOLD
The default array size threshold value.
|
static String |
PROPERTY_MODULE_SCAN
The property used to enable module scan.
|
static String |
PROPERTY_USE_BEAN_INTROSPECTION
The property used to enable bean introspection.
|
Constructor and Description |
---|
JacksonConfiguration() |
Modifier and Type | Method and Description |
---|---|
static <T> com.fasterxml.jackson.databind.JavaType |
constructType(Argument<T> type,
com.fasterxml.jackson.databind.type.TypeFactory typeFactory)
Constructors a JavaType for the given argument and type factory.
|
int |
getArraySizeThreshold() |
String |
getDateFormat() |
com.fasterxml.jackson.databind.ObjectMapper.DefaultTyping |
getDefaultTyping() |
Map<com.fasterxml.jackson.databind.DeserializationFeature,Boolean> |
getDeserializationSettings() |
Map<com.fasterxml.jackson.core.JsonGenerator.Feature,Boolean> |
getGeneratorSettings() |
Locale |
getLocale() |
Map<com.fasterxml.jackson.databind.MapperFeature,Boolean> |
getMapperSettings() |
Map<com.fasterxml.jackson.core.JsonParser.Feature,Boolean> |
getParserSettings() |
com.fasterxml.jackson.databind.PropertyNamingStrategy |
getPropertyNamingStrategy() |
com.fasterxml.jackson.annotation.JsonInclude.Include |
getSerializationInclusion() |
Map<com.fasterxml.jackson.databind.SerializationFeature,Boolean> |
getSerializationSettings() |
TimeZone |
getTimeZone() |
boolean |
isBeanIntrospectionModule()
Whether the
BeanIntrospection should be used for reflection free object serialialization/deserialialization. |
boolean |
isModuleScan()
Whether Jackson modules should be scanned for.
|
void |
setArraySizeThreshold(int arraySizeThreshold)
Sets the array size threshold for data binding.
|
void |
setBeanIntrospectionModule(boolean beanIntrospectionModule)
Whether the
BeanIntrospection should be used for reflection free object serialialization/deserialialization. |
void |
setDateFormat(String dateFormat)
Sets the default date format to use.
|
void |
setDefaultTyping(com.fasterxml.jackson.databind.ObjectMapper.DefaultTyping defaultTyping)
Sets the global defaultTyping using for Polymorphic handling.
|
void |
setDeserialization(Map<com.fasterxml.jackson.databind.DeserializationFeature,Boolean> deserialization)
Sets the deserialization features to use.
|
void |
setGenerator(Map<com.fasterxml.jackson.core.JsonGenerator.Feature,Boolean> generator)
Sets the generator features to use.
|
void |
setLocale(Locale locale)
Sets the locale to use.
|
void |
setMapper(Map<com.fasterxml.jackson.databind.MapperFeature,Boolean> mapper)
Sets the object mapper features to use.
|
void |
setModuleScan(boolean moduleScan)
Sets whether to scan for modules or not (defaults to true).
|
void |
setParser(Map<com.fasterxml.jackson.core.JsonParser.Feature,Boolean> parser)
Sets the parser features to use.
|
void |
setPropertyNamingStrategy(com.fasterxml.jackson.databind.PropertyNamingStrategy propertyNamingStrategy)
Sets the property naming strategy.
|
void |
setSerialization(Map<com.fasterxml.jackson.databind.SerializationFeature,Boolean> serialization)
Sets the serialization features to use.
|
void |
setSerializationInclusion(com.fasterxml.jackson.annotation.JsonInclude.Include serializationInclusion)
Sets the serialization inclusion mode.
|
void |
setTimeZone(TimeZone timeZone)
Sets the timezone to use.
|
public static final int DEFAULT_ARRAYSIZETHRESHOLD
public static final String PROPERTY_MODULE_SCAN
public static final String PROPERTY_USE_BEAN_INTROSPECTION
public boolean isBeanIntrospectionModule()
BeanIntrospection
should be used for reflection free object serialialization/deserialialization.public void setBeanIntrospectionModule(boolean beanIntrospectionModule)
BeanIntrospection
should be used for reflection free object serialialization/deserialialization.beanIntrospectionModule
- True if it shouldpublic boolean isModuleScan()
public void setModuleScan(boolean moduleScan)
moduleScan
- True if module scan should be enabledpublic com.fasterxml.jackson.annotation.JsonInclude.Include getSerializationInclusion()
public com.fasterxml.jackson.databind.ObjectMapper.DefaultTyping getDefaultTyping()
public Locale getLocale()
public TimeZone getTimeZone()
public String getDateFormat()
public Map<com.fasterxml.jackson.databind.SerializationFeature,Boolean> getSerializationSettings()
public Map<com.fasterxml.jackson.databind.DeserializationFeature,Boolean> getDeserializationSettings()
public Map<com.fasterxml.jackson.databind.MapperFeature,Boolean> getMapperSettings()
public Map<com.fasterxml.jackson.core.JsonParser.Feature,Boolean> getParserSettings()
public Map<com.fasterxml.jackson.core.JsonGenerator.Feature,Boolean> getGeneratorSettings()
public int getArraySizeThreshold()
public com.fasterxml.jackson.databind.PropertyNamingStrategy getPropertyNamingStrategy()
public void setDateFormat(String dateFormat)
dateFormat
- The date formatpublic void setLocale(Locale locale)
locale
- The localepublic void setTimeZone(TimeZone timeZone)
timeZone
- The timezonepublic void setArraySizeThreshold(int arraySizeThreshold)
arraySizeThreshold
- The array size thresholdpublic void setSerialization(Map<com.fasterxml.jackson.databind.SerializationFeature,Boolean> serialization)
serialization
- The serialization features.public void setDeserialization(Map<com.fasterxml.jackson.databind.DeserializationFeature,Boolean> deserialization)
deserialization
- The deserialiation features.public void setMapper(Map<com.fasterxml.jackson.databind.MapperFeature,Boolean> mapper)
mapper
- The object mapper featurespublic void setParser(Map<com.fasterxml.jackson.core.JsonParser.Feature,Boolean> parser)
parser
- The parser featurespublic void setGenerator(Map<com.fasterxml.jackson.core.JsonGenerator.Feature,Boolean> generator)
generator
- The generator featurespublic void setSerializationInclusion(com.fasterxml.jackson.annotation.JsonInclude.Include serializationInclusion)
serializationInclusion
- The serialization inclusion modepublic void setDefaultTyping(com.fasterxml.jackson.databind.ObjectMapper.DefaultTyping defaultTyping)
defaultTyping
- The defaultTypingpublic void setPropertyNamingStrategy(com.fasterxml.jackson.databind.PropertyNamingStrategy propertyNamingStrategy)
propertyNamingStrategy
- The property naming strategypublic static <T> com.fasterxml.jackson.databind.JavaType constructType(@Nonnull Argument<T> type, @Nonnull com.fasterxml.jackson.databind.type.TypeFactory typeFactory)
T
- The generic typetype
- The typetypeFactory
- The type factory