JacksonAnnotationIntrospector that is needed to support
additional xml-specific annotation that Jackson provides. Note, however, that
there is no JAXB annotation support here; that is provided with
separate introspector (see
https://github.com/FasterXML/jackson-modules-base/tree/master/jaxb,
class com.fasterxml.jackson.module.jaxb.JaxbAnnotationIntrospector).
| Modifier and Type | Field and Description |
|---|---|
| protected boolean | |
| private static final Class | |
| public static final boolean | DEFAULT_USE_WRAPPER
For backwards compatibility with 2.0, the default behavior is to assume use of List wrapper if no annotations are used. |
| private static final long |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected StdTypeResolverBuilder | _constructStdTypeResolverBuilder()
We will override this method so that we can return instance
that cleans up type id property name to be a valid xml name.
|
| protected TypeResolverBuilder | _constructStdTypeResolverBuilder(MapperConfig<?> config, JsonTypeInfo.
TypeResolverBuilder
implementation.
|
| protected PropertyName | |
| public void | findAndAddVirtualProperties(MapperConfig<?> config, AnnotatedClass ac, List<BeanPropertyWriter> properties)
Overrides com. |
| public PropertyName | findNameForDeserialization(Annotated
Annotated entity to check a)Overrides com. |
| public PropertyName | findNameForSerialization(Annotated
Property accessor to check a)Overrides com. |
| public String | findNamespace(MapperConfig<?>
Configuration settings in effect config, Annotated Annotated entity to introspect ann)Implements com. |
| public PropertyName | findRootName(AnnotatedClass
Annotated class to introspect ac)Overrides com. |
| public PropertyName | findWrapperName(Annotated ann)
Overrides com. |
| public Boolean | isOutputAsAttribute(MapperConfig<?>
Configuration settings in effect config, Annotated Annotated entity to introspect ann)Implements com. |
| public Boolean | isOutputAsCData(MapperConfig<?>
Configuration settings in effect config, Annotated Annotated entity to introspect ann)Implements com. |
| public Boolean | isOutputAsText(MapperConfig<?>
Configuration settings in effect config, Annotated Annotated entity to introspect ann)Implements com. |
| public void |
| _cfgDefaultUseWrapper | back to summary |
|---|---|
| protected boolean _cfgDefaultUseWrapper | |
| ANNOTATIONS_TO_INFER_XML_PROP | back to summary |
|---|---|
private static final Class<? extends Annotation>[] ANNOTATIONS_TO_INFER_XML_PROP
| |
| DEFAULT_USE_WRAPPER | back to summary |
|---|---|
| public static final boolean DEFAULT_USE_WRAPPER For backwards compatibility with 2.0, the default behavior is to assume use of List wrapper if no annotations are used. | |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides com. | |
| JacksonXmlAnnotationIntrospector | back to summary |
|---|---|
| public JacksonXmlAnnotationIntrospector() | |
| JacksonXmlAnnotationIntrospector | back to summary |
|---|---|
| public JacksonXmlAnnotationIntrospector(boolean defaultUseWrapper) | |
| _constructStdTypeResolverBuilder | back to summary |
|---|---|
| protected StdTypeResolverBuilder _constructStdTypeResolverBuilder() We will override this method so that we can return instance that cleans up type id property name to be a valid xml name.
| |
| _constructStdTypeResolverBuilder | back to summary |
|---|---|
| protected TypeResolverBuilder Helper method for constructing standard
| |
| _findXmlName | back to summary |
|---|---|
| protected PropertyName _findXmlName(Annotated a) | |
| findAndAddVirtualProperties | back to summary |
|---|---|
| public void findAndAddVirtualProperties(MapperConfig<?> config, AnnotatedClass ac, List<BeanPropertyWriter> properties) Overrides com. Due to issue [dataformat-xml#578] need to suppress calls to this method to avoid duplicate virtual properties from being added. Not elegant but .. works.
| |
| findNameForDeserialization | back to summary |
|---|---|
| public PropertyName findNameForDeserialization(Annotated a) Overrides com. Doc from com. Method for checking whether given property accessors (method,
field) has an annotation that suggests property name to use
for deserialization (reading JSON into POJOs).
Should return null if no annotation
is found; otherwise a non-null name (possibly
| |
| findNameForSerialization | back to summary |
|---|---|
| public PropertyName findNameForSerialization(Annotated a) Overrides com. Doc from com. Method for checking whether given property accessors (method,
field) has an annotation that suggests property name to use
for serialization.
Should return null if no annotation
is found; otherwise a non-null name (possibly
| |
| findNamespace | back to summary |
|---|---|
| public String findNamespace(MapperConfig<?> config, Annotated ann) Implements com. Doc from com. Method that can be called to figure out generic namespace property for an annotated object.
| |
| findRootName | back to summary |
|---|---|
| public PropertyName findRootName(AnnotatedClass ac) Overrides com. Doc from com. Method for locating name used as "root name" (for use by some serializers when outputting root-level object -- mostly for XML compatibility purposes) for given class, if one is defined. Returns null if no declaration found; can return explicit empty String, which is usually ignored as well as null. Note method signature changed in 2.1, to return
| |
| findWrapperName | back to summary |
|---|---|
| public PropertyName findWrapperName(Annotated ann) Overrides com. Doc from com. Method used to check if specified property has annotation that indicates that it should be wrapped in an element; and if so, name to use. Note that not all serializers and deserializers support use this method: currently (2.1) it is only used by XML-backed handlers.
| |
| isOutputAsAttribute | back to summary |
|---|---|
| public Boolean isOutputAsAttribute(MapperConfig<?> config, Annotated ann) Implements com. Doc from com. Method used to check whether given annotated element (field, method, constructor parameter) has indicator that suggests it be output as an XML attribute or not (if not, then as element)
| |
| isOutputAsCData | back to summary |
|---|---|
| public Boolean isOutputAsCData(MapperConfig<?> config, Annotated ann) Implements com. Doc from com. Method used to check whether given annotated element (field, method, constructor parameter) has indicator that suggests it should be wrapped in a CDATA tag.
| |
| isOutputAsText | back to summary |
|---|---|
| public Boolean isOutputAsText(MapperConfig<?> config, Annotated ann) Implements com. Doc from com. Method used to check whether given annotated element (field, method, constructor parameter) has indicator that suggests it should be serialized as text, without element wrapper.
| |
| setDefaultUseWrapper | back to summary |
|---|---|
| public void setDefaultUseWrapper(boolean b) | |