Module tools.jackson.dataformat.xml
Package tools.jackson.dataformat.xml.ser
Class XmlBeanPropertyWriter
java.lang.Object
tools.jackson.databind.introspect.ConcreteBeanPropertyBase
tools.jackson.databind.ser.PropertyWriter
tools.jackson.databind.ser.BeanPropertyWriter
tools.jackson.dataformat.xml.ser.XmlBeanPropertyWriter
- All Implemented Interfaces:
tools.jackson.core.util.Named,tools.jackson.databind.BeanProperty,tools.jackson.databind.util.FullyNamed
public class XmlBeanPropertyWriter
extends tools.jackson.databind.ser.BeanPropertyWriter
Property writer sub-class used for handling element wrapping needed for serializing
collection (array, Collection; possibly Map) types.
-
Nested Class Summary
Nested classes/interfaces inherited from interface tools.jackson.databind.BeanProperty
tools.jackson.databind.BeanProperty.Bogus, tools.jackson.databind.BeanProperty.StdNested classes/interfaces inherited from interface tools.jackson.core.util.Named
tools.jackson.core.util.Named.StringAsNamed -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final QNameElement name used for items in the collectionprotected final QNameElement name used as wrapper for collection.Fields inherited from class tools.jackson.databind.ser.BeanPropertyWriter
_accessor, _cfgSerializationType, _contextAnnotations, _declaredType, _dynamicSerializers, _includeInViews, _internalSettings, _member, _name, _nonTrivialBaseType, _nullSerializer, _serializer, _suppressableValue, _suppressNulls, _typeSerializer, _wrapperName, MARKER_FOR_EMPTYFields inherited from class tools.jackson.databind.introspect.ConcreteBeanPropertyBase
_aliases, _metadataFields inherited from interface tools.jackson.databind.BeanProperty
EMPTY_FORMAT, EMPTY_INCLUDE -
Constructor Summary
ConstructorsConstructorDescriptionXmlBeanPropertyWriter(tools.jackson.databind.ser.BeanPropertyWriter wrapped, tools.jackson.databind.PropertyName wrapperName, tools.jackson.databind.PropertyName wrappedName) XmlBeanPropertyWriter(tools.jackson.databind.ser.BeanPropertyWriter wrapped, tools.jackson.databind.PropertyName wrapperName, tools.jackson.databind.PropertyName wrappedName, tools.jackson.databind.ValueSerializer<Object> serializer) -
Method Summary
Modifier and TypeMethodDescriptionvoidserializeAsProperty(Object bean, tools.jackson.core.JsonGenerator g, tools.jackson.databind.SerializationContext ctxt) Overridden version so that we can wrap output within wrapper element if and as necessary.Methods inherited from class tools.jackson.databind.ser.BeanPropertyWriter
_depositSchemaProperty, _findAndAddDynamic, _handleSelfReference, _new, assignNullSerializer, assignSerializer, assignTypeSerializer, depositSchemaProperty, fixAccess, get, getAnnotation, getContextAnnotation, getFullName, getInternalSetting, getMember, getName, getSerializationType, getSerializedName, getSerializer, getType, getTypeSerializer, getViews, getWrapperName, hasNullSerializer, hasSerializer, isUnwrapping, removeInternalSetting, rename, serializeAsElement, serializeAsOmittedElement, serializeAsOmittedProperty, setInternalSetting, setNonTrivialBaseType, toString, unwrappingWriter, willSuppressNulls, wouldConflictWithNameMethods inherited from class tools.jackson.databind.ser.PropertyWriter
findAnnotationMethods inherited from class tools.jackson.databind.introspect.ConcreteBeanPropertyBase
findAliases, findFormatOverrides, findPropertyFormat, findPropertyInclusion, getMetadata, isRequired, isVirtualMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface tools.jackson.databind.util.FullyNamed
hasName
-
Field Details
-
_wrapperQName
Element name used as wrapper for collection. -
_wrappedQName
Element name used for items in the collection
-
-
Constructor Details
-
XmlBeanPropertyWriter
public XmlBeanPropertyWriter(tools.jackson.databind.ser.BeanPropertyWriter wrapped, tools.jackson.databind.PropertyName wrapperName, tools.jackson.databind.PropertyName wrappedName) -
XmlBeanPropertyWriter
public XmlBeanPropertyWriter(tools.jackson.databind.ser.BeanPropertyWriter wrapped, tools.jackson.databind.PropertyName wrapperName, tools.jackson.databind.PropertyName wrappedName, tools.jackson.databind.ValueSerializer<Object> serializer)
-
-
Method Details
-
serializeAsProperty
public void serializeAsProperty(Object bean, tools.jackson.core.JsonGenerator g, tools.jackson.databind.SerializationContext ctxt) throws Exception Overridden version so that we can wrap output within wrapper element if and as necessary.- Overrides:
serializeAsPropertyin classtools.jackson.databind.ser.BeanPropertyWriter- Throws:
Exception
-