SetupContext used by
ObjectMapper.
| Modifier and Type | Field and Description |
|---|---|
| protected final MapperBuilder | |
| protected final ConfigOverrides |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected DeserializerFactory | |
| protected SerializerFactory | |
| protected void | |
| protected void | |
| protected TokenStreamFactory | |
| public JacksonModule. | addAbstractTypeResolver(AbstractTypeResolver resolver)
Implements tools. Method that module can use to register additional
|
| public JacksonModule. | addDeserializerModifier(ValueDeserializerModifier modifier)
Implements tools. Method that module can use to register additional modifier objects to customize configuration and construction of bean deserializers. |
| public JacksonModule. | addDeserializers(Deserializers d)
Implements tools. Method that module can use to register additional deserializers to use for handling types. |
| public JacksonModule. | addHandler(DeserializationProblemHandler handler)
Implements tools. Add a deserialization problem handler |
| public JacksonModule. | addKeyDeserializers(KeyDeserializers kd)
Implements tools. Method that module can use to register additional deserializers to use for handling Map key values (which are separate from value deserializers because they are always serialized from String values) |
| public JacksonModule. | addKeySerializers(Serializers s)
Implements tools. Method that module can use to register additional serializers to use for
handling Map key values (which are separate from value serializers because
they must write |
| public JacksonModule. | addSerializerModifier(ValueSerializerModifier modifier)
Implements tools. Method that module can use to register additional modifier objects to customize configuration and construction of bean serializers. |
| public JacksonModule. | addSerializers(Serializers s)
Implements tools. Method that module can use to register additional serializers to use for handling types. |
| public JacksonModule. | addTypeModifier(TypeModifier modifier)
Implements tools. Method that module can use to register additional
|
| public JacksonModule. | addValueInstantiators(ValueInstantiators instantiators)
Implements tools. Method that module can use to register additional |
| public JacksonModule. | appendAnnotationIntrospector(AnnotationIntrospector ai)
Implements tools. Method for registering specified |
| public void | applyChanges(MapperBuilder<?, ?> b)
Method called after all changes have been applied through this context, to propagate buffered or pending changes (if any) back to builder. |
| public MutableConfigOverride | configOverride(Class<?> type)
Implements tools. "Mutant accessor" for getting a mutable configuration override object for given type, needed to add or change per-type overrides applied to properties of given type. |
| public DatatypeFeatures | |
| public String | |
| public Version | getMapperVersion()
Implements tools. Method that returns version information about |
| public Object | getOwner()
Implements tools. Fallback access method that allows modules to refer to the
|
| public JacksonModule. | insertAnnotationIntrospector(AnnotationIntrospector ai)
Implements tools. Method for registering specified |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public boolean | |
| public JacksonModule. | overrideDefaultNullKeySerializer(ValueSerializer<?> ser)
Implements tools. Method that module can use to override handler called to write JSON Object key
for |
| public JacksonModule. | overrideDefaultNullValueSerializer(ValueSerializer<?> ser)
Implements tools. Method that module can use to override handler called to write Java `null` as a value (Property or Map value, Collection/array element). |
| public JacksonModule. | overrideInjectableValues(UnaryOperator<InjectableValues> v)
Implements tools. Replace default |
| public JacksonModule. | registerSubtypes(Class<?>... subtypes)
Implements tools. Method for registering specified classes as subtypes (of supertype(s) they have) |
| public JacksonModule. | registerSubtypes(NamedType... subtypes)
Implements tools. Method for registering specified classes as subtypes (of supertype(s) they have), using specified type names. |
| public JacksonModule. | registerSubtypes(Collection<Class<?>> subtypes)
Implements tools. Method for registering specified classes as subtypes (of supertype(s) they have) |
| public JacksonModule. | setMixIn(Class<?> target, Class<?> mixinSource)
Implements tools. Method used for defining mix-in annotations to use for augmenting specified class or interface. |
| public TokenStreamFactory | |
| public TypeFactory | typeFactory()
Implements tools. Accessor for finding |
| _builder | back to summary |
|---|---|
| protected final MapperBuilder<?, ?> _builder | |
| _configOverrides | back to summary |
|---|---|
| protected final ConfigOverrides _configOverrides | |
| ModuleContextBase | back to summary |
|---|---|
| public ModuleContextBase(MapperBuilder<?, ?> b, ConfigOverrides configOverrides) | |
| _deserializerFactory | back to summary |
|---|---|
| protected DeserializerFactory _deserializerFactory() | |
| _serializerFactory | back to summary |
|---|---|
| protected SerializerFactory _serializerFactory() | |
| _set | back to summary |
|---|---|
| protected void _set(DeserializerFactory f) | |
| _set | back to summary |
|---|---|
| protected void _set(SerializerFactory f) | |
| _streamFactory | back to summary |
|---|---|
| protected TokenStreamFactory _streamFactory() | |
| addAbstractTypeResolver | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional
| |
| addDeserializerModifier | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional modifier objects to customize configuration and construction of bean deserializers.
| |
| addDeserializers | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional deserializers to use for handling types.
| |
| addHandler | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Add a deserialization problem handler
| |
| addKeyDeserializers | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional deserializers to use for handling Map key values (which are separate from value deserializers because they are always serialized from String values)
| |
| addKeySerializers | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional serializers to use for
handling Map key values (which are separate from value serializers because
they must write
| |
| addSerializerModifier | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional modifier objects to customize configuration and construction of bean serializers.
| |
| addSerializers | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional serializers to use for handling types.
| |
| addTypeModifier | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional
| |
| addValueInstantiators | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to register additional
| |
| appendAnnotationIntrospector | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method for registering specified
| |
| applyChanges | back to summary |
|---|---|
| public void applyChanges(MapperBuilder<?, ?> b) Method called after all changes have been applied through this context, to propagate buffered or pending changes (if any) back to builder. Note that base implementation does nothing here; it is only provded in case sub-classes might need it. | |
| configOverride | back to summary |
|---|---|
| public MutableConfigOverride configOverride(Class<?> type) Implements tools. Doc from tools. "Mutant accessor" for getting a mutable configuration override object for given type, needed to add or change per-type overrides applied to properties of given type. Usage is through returned object by colling "setter" methods, which directly modify override object and take effect directly. For example you can do
mapper.configOverride(java.util.Date.class)
.setFormat(JsonFormat.Value.forPattern("yyyy-MM-dd"));
to change the default format to use for properties of type
java. (possibly further overridden by per-property
annotations)
| |
| datatypeFeatures | back to summary |
|---|---|
| public DatatypeFeatures datatypeFeatures() Implements tools.
| |
| getFormatName | back to summary |
|---|---|
| public String getFormatName() Implements tools.
| |
| getMapperVersion | back to summary |
|---|---|
| public Version getMapperVersion() Implements tools. Doc from tools. Method that returns version information about
| |
| getOwner | back to summary |
|---|---|
| public Object getOwner() Implements tools. Doc from tools. Fallback access method that allows modules to refer to the
Note use of this method is discouraged, as it allows access to things Modules typically should not modify. It is included, however, to allow access to new features in cases where Module API has not yet been extended, or there are oversights.
Return value is chosen to force casting, to make caller aware that
this is a fallback accessor, used only when everything else fails:
type is, however, guaranteed to be
| |
| insertAnnotationIntrospector | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method for registering specified
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(MapperFeature f) Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(DeserializationFeature f) Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(SerializationFeature f) Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(TokenStreamFactory. Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(StreamReadFeature f) Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(StreamWriteFeature f) Implements tools.
| |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled(DatatypeFeature f) Implements tools.
| |
| overrideDefaultNullKeySerializer | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to override handler called to write JSON Object key
for
| |
| overrideDefaultNullValueSerializer | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method that module can use to override handler called to write Java `null` as a value (Property or Map value, Collection/array element).
| |
| overrideInjectableValues | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Replace default
| |
| registerSubtypes | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method for registering specified classes as subtypes (of supertype(s) they have)
| |
| registerSubtypes | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method for registering specified classes as subtypes (of supertype(s) they have), using specified type names.
| |
| registerSubtypes | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method for registering specified classes as subtypes (of supertype(s) they have)
| |
| setMixIn | back to summary |
|---|---|
| public JacksonModule. Implements tools. Doc from tools. Method used for defining mix-in annotations to use for augmenting
specified class or interface.
All annotations from
Note mix-ins are registered both for serialization and deserialization (which can be different internally). Note currently only one set of mix-in annotations can be defined for a single class; so if multiple modules register mix-ins, highest priority one (last one registered) will have priority over other modules.
| |
| tokenStreamFactory | back to summary |
|---|---|
| public TokenStreamFactory tokenStreamFactory() Implements tools.
| |
| typeFactory | back to summary |
|---|---|
| public TypeFactory typeFactory() Implements tools. Doc from tools. Accessor for finding Note since it is possible that other modules might change or replace TypeFactory, use of this method adds order-dependency for registrations.
| |