public static final class CosmosJsonModule.TypePropertyWriter
extends com.fasterxml.jackson.databind.ser.VirtualBeanPropertyWriter
property writer for adding the class name to the JSON
representation of an object.
Use it with JsonAppend to add virtual properties in addition to regular ones.
CosmosJsonModule.ThrowableMixIn,
Serialized Form_accessorMethod, _cfgSerializationType, _contextAnnotations, _declaredType, _dynamicSerializers, _field, _includeInViews, _internalSettings, _member, _name, _nonTrivialBaseType, _nullSerializer, _serializer, _suppressableValue, _suppressNulls, _typeSerializer, _wrapperName, MARKER_FOR_EMPTY| Constructor and Description |
|---|
TypePropertyWriter()
Initializes a newly created
CosmosJsonModule.TypePropertyWriter. |
TypePropertyWriter(com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition propertyDefinition,
com.fasterxml.jackson.databind.util.Annotations annotations,
com.fasterxml.jackson.databind.JavaType javaType)
Initializes a newly created
CosmosJsonModule.TypePropertyWriter. |
| Modifier and Type | Method and Description |
|---|---|
protected Object |
value(Object bean,
com.fasterxml.jackson.core.JsonGenerator generator,
com.fasterxml.jackson.databind.SerializerProvider provider) |
com.fasterxml.jackson.databind.ser.VirtualBeanPropertyWriter |
withConfig(com.fasterxml.jackson.databind.cfg.MapperConfig<?> mapperConfig,
com.fasterxml.jackson.databind.introspect.AnnotatedClass annotatedClass,
com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition propertyDefinition,
com.fasterxml.jackson.databind.JavaType javaType)
A factory method for constructing a
CosmosJsonModule.TypePropertyWriter. |
_suppressableValue, _suppressNulls, isVirtual, serializeAsElement, serializeAsField_depositSchemaProperty, _findAndAddDynamic, _handleSelfReference, _new, assignNullSerializer, assignSerializer, assignTypeSerializer, depositSchemaProperty, depositSchemaProperty, fixAccess, get, getAnnotation, getContextAnnotation, getFullName, getGenericPropertyType, getInternalSetting, getMember, getName, getPropertyType, getRawSerializationType, getSerializationType, getSerializedName, getSerializer, getType, getTypeSerializer, getViews, getWrapperName, hasNullSerializer, hasSerializer, isUnwrapping, removeInternalSetting, rename, serializeAsOmittedField, serializeAsPlaceholder, setInternalSetting, setNonTrivialBaseType, toString, unwrappingWriter, willSuppressNulls, wouldConflictWithNamepublic TypePropertyWriter()
CosmosJsonModule.TypePropertyWriter.
Jackson requires a parameterless constructor for all PropertyWriter classes.
public TypePropertyWriter(com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition propertyDefinition,
com.fasterxml.jackson.databind.util.Annotations annotations,
com.fasterxml.jackson.databind.JavaType javaType)
CosmosJsonModule.TypePropertyWriter.
Jackson requires a constructor with these parameters for all PropertyWriter classes.
propertyDefinition - A property definition.annotations - The annotations present on the property.javaType - The JavaType of the property value to be written.public com.fasterxml.jackson.databind.ser.VirtualBeanPropertyWriter withConfig(com.fasterxml.jackson.databind.cfg.MapperConfig<?> mapperConfig,
com.fasterxml.jackson.databind.introspect.AnnotatedClass annotatedClass,
com.fasterxml.jackson.databind.introspect.BeanPropertyDefinition propertyDefinition,
com.fasterxml.jackson.databind.JavaType javaType)
CosmosJsonModule.TypePropertyWriter.withConfig in class com.fasterxml.jackson.databind.ser.VirtualBeanPropertyWritermapperConfig - Mapper configuration.annotatedClass - An annotated class.propertyDefinition - A property definition.javaType - The JavaType of the property value to be written.Copyright © 2021. All rights reserved.