BeanSerializerFactory that is used to
construct BeanPropertyWriter instances. Can be sub-classed
to change behavior.
| Modifier and Type | Field and Description |
|---|---|
| protected final AnnotationIntrospector | |
| protected final BeanDescription | |
| protected final SerializationConfig | |
| protected Object | _defaultBean
If a property has serialization inclusion value of
|
| protected final JsonInclude. | _defaultInclusion
Default inclusion mode for properties of the POJO for which properties are collected; possibly overridden on per-property basis. |
| protected final boolean | _useRealPropertyDefaults
Marker flag used to indicate that "real" default values are to be used
for properties, as per per-type value inclusion of type |
| private static final Object |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| protected BeanPropertyWriter | _constructPropertyWriter(BeanPropertyDefinition propDef, AnnotatedMember member, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, boolean suppressNulls, Object suppressableValue, Class<?>[] includeInViews)
Overridable factory method for actual construction of |
| protected Object | |
| protected BeanPropertyWriter | buildWriter(SerializerProvider prov, BeanPropertyDefinition propDef, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, TypeSerializer
Optional explicit type information serializer
to use for contained values (only used for properties that are
of container type) contentTypeSer, AnnotatedMember am, boolean defaultUseStaticTyping)
|
| protected JavaType | findSerializationType(Annotated a, boolean useStaticTyping, JavaType declaredType)
Method that will try to determine statically defined type of property being serialized, based on annotations (for overrides), and alternatively declared type (if static typing for serialization is enabled). |
| public Annotations | |
| protected Object | |
| protected Object | |
| protected Object | getPropertyDefaultValue(String name, AnnotatedMember member, JavaType type)
Deprecated
Since 2.9 since this will not allow determining difference between "no default instance"
case and default being `null`.
Accessor used to find out "default value" for given property, to use for
comparing values to serialize, to determine whether to exclude value from serialization with
inclusion type of com..
|
| _annotationIntrospector | back to summary |
|---|---|
| protected final AnnotationIntrospector _annotationIntrospector | |
| _beanDesc | back to summary |
|---|---|
| protected final BeanDescription _beanDesc | |
| _config | back to summary |
|---|---|
| protected final SerializationConfig _config | |
| _defaultBean | back to summary |
|---|---|
| protected Object _defaultBean If a property has serialization inclusion value of
Note only used if enclosing class defines NON_DEFAULT, but NOT if it is the global default OR per-property override. | |
| _defaultInclusion | back to summary |
|---|---|
| protected final JsonInclude. Default inclusion mode for properties of the POJO for which properties are collected; possibly overridden on per-property basis. Combines global inclusion defaults and per-type (annotation and type-override) inclusion overrides. | |
| _useRealPropertyDefaults | back to summary |
|---|---|
| protected final boolean _useRealPropertyDefaults Marker flag used to indicate that "real" default values are to be used
for properties, as per per-type value inclusion of type
| |
| NO_DEFAULT_MARKER | back to summary |
|---|---|
| private static final Object NO_DEFAULT_MARKER | |
| PropertyBuilder | back to summary |
|---|---|
| public PropertyBuilder(SerializationConfig config, BeanDescription beanDesc) | |
| _constructPropertyWriter | back to summary |
|---|---|
| protected BeanPropertyWriter _constructPropertyWriter(BeanPropertyDefinition propDef, AnnotatedMember member, Annotations contextAnnotations, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, JavaType serType, boolean suppressNulls, Object suppressableValue, Class<?>[] includeInViews) throws JsonMappingException Overridable factory method for actual construction of
| |
| _throwWrapped | back to summary |
|---|---|
| protected Object _throwWrapped(Exception e, String propName, Object defaultBean) | |
| buildWriter | back to summary |
|---|---|
protected BeanPropertyWriter buildWriter(SerializerProvider prov, BeanPropertyDefinition propDef, JavaType declaredType, JsonSerializer<?> ser, TypeSerializer typeSer, TypeSerializer contentTypeSer, AnnotatedMember am, boolean defaultUseStaticTyping) throws JsonMappingException
| |
| findSerializationType | back to summary |
|---|---|
| protected JavaType findSerializationType(Annotated a, boolean useStaticTyping, JavaType declaredType) throws JsonMappingException Method that will try to determine statically defined type of property being serialized, based on annotations (for overrides), and alternatively declared type (if static typing for serialization is enabled). If neither can be used (no annotations, dynamic typing), returns null. | |
| getClassAnnotations | back to summary |
|---|---|
| public Annotations getClassAnnotations() | |
| getDefaultBean | back to summary |
|---|---|
| protected Object getDefaultBean() | |
| getDefaultValue | back to summary |
|---|---|
| protected Object getDefaultValue(JavaType type)
Deprecated Since 2.9
| |
| getPropertyDefaultValue | back to summary |
|---|---|
| protected Object getPropertyDefaultValue(String name, AnnotatedMember member, JavaType type)
Deprecated Since 2.9 since this will not allow determining difference between "no default instance" case and default being `null`. Accessor used to find out "default value" for given property, to use for
comparing values to serialize, to determine whether to exclude value from serialization with
inclusion type of
Note that returning of pseudo-type
| |