public ObjectArraySerializer(JavaType elemType, boolean staticTyping, TypeSerializer vts, JsonSerializer<Object> elementSerializer) { super(Object[].class); _elementType = elemType; _staticTyping = staticTyping; _valueTypeSerializer = vts; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _elementSerializer = elementSerializer; }
Object readResolve() { // Since it's transient, and since JDK serialization by-passes ctor, need this: _dynamicSerializers = PropertySerializerMap.emptyForProperties(); return this; }
@SuppressWarnings("unchecked") public ObjectArraySerializer(ObjectArraySerializer src, BeanProperty property, TypeSerializer vts, JsonSerializer<?> elementSerializer, Boolean unwrapSingle) { super(src, property, unwrapSingle); _elementType = src._elementType; _valueTypeSerializer = vts; _staticTyping = src._staticTyping; // [databind#2181]: may not be safe to reuse, start from empty _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _elementSerializer = (JsonSerializer<Object>) elementSerializer; }
public Dynamic() { super(String.class, false); _dynamicSerializers = PropertySerializerMap.emptyForProperties(); }
public MapEntrySerializer(JavaType type, JavaType keyType, JavaType valueType, boolean staticTyping, TypeSerializer vts, BeanProperty property) { super(type); _entryType = type; _keyType = keyType; _valueType = valueType; _valueTypeIsStatic = staticTyping; _valueTypeSerializer = vts; _property = property; _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); _suppressableValue = null; _suppressNulls = false; }
@SuppressWarnings("unchecked") protected AsArraySerializerBase(AsArraySerializerBase<?> src, BeanProperty property, TypeSerializer vts, JsonSerializer<?> elementSerializer, Boolean unwrapSingle) { super(src); _elementType = src._elementType; _staticTyping = src._staticTyping; _valueTypeSerializer = vts; _property = property; _elementSerializer = (JsonSerializer<Object>) elementSerializer; // [databind#2181]: may not be safe to reuse, start from empty _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _unwrapSingle = unwrapSingle; }
@SuppressWarnings("unchecked") protected ReferenceTypeSerializer(ReferenceTypeSerializer<?> base, BeanProperty property, TypeSerializer vts, JsonSerializer<?> valueSer, NameTransformer unwrapper, Object suppressableValue, boolean suppressNulls) { super(base); _referredType = base._referredType; // [databind#2181]: may not be safe to reuse, start from empty _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _property = property; _valueTypeSerializer = vts; _valueSerializer = (JsonSerializer<Object>) valueSer; _unwrapper = unwrapper; _suppressableValue = suppressableValue; _suppressNulls = suppressNulls; }
protected MapSerializer(MapSerializer src, Object filterId, boolean sortKeys) { super(Map.class, false); _ignoredEntries = src._ignoredEntries; _keyType = src._keyType; _valueType = src._valueType; _valueTypeIsStatic = src._valueTypeIsStatic; _valueTypeSerializer = src._valueTypeSerializer; _keySerializer = src._keySerializer; _valueSerializer = src._valueSerializer; // [databind#2181]: may not be safe to reuse, start from empty _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); _property = src._property; _filterId = filterId; _sortKeys = sortKeys; _suppressableValue = src._suppressableValue; _suppressNulls = src._suppressNulls; }
@SuppressWarnings("unchecked") protected MapEntrySerializer(MapEntrySerializer src, BeanProperty property, TypeSerializer vts, JsonSerializer<?> keySer, JsonSerializer<?> valueSer, Object suppressableValue, boolean suppressNulls) { super(Map.class, false); _entryType = src._entryType; _keyType = src._keyType; _valueType = src._valueType; _valueTypeIsStatic = src._valueTypeIsStatic; _valueTypeSerializer = src._valueTypeSerializer; _keySerializer = (JsonSerializer<Object>) keySer; _valueSerializer = (JsonSerializer<Object>) valueSer; // [databind#2181]: may not be safe to reuse, start from empty _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); _property = src._property; _suppressableValue = suppressableValue; _suppressNulls = suppressNulls; }
/** * @deprecated Since 2.5 Use {@link #emptyForProperties} instead */ @Deprecated public static PropertySerializerMap emptyMap() { return emptyForProperties(); }
@SuppressWarnings("unchecked") protected MapSerializer(MapSerializer src, BeanProperty property, JsonSerializer<?> keySerializer, JsonSerializer<?> valueSerializer, Set<String> ignoredEntries) { super(Map.class, false); _ignoredEntries = ((ignoredEntries == null) || ignoredEntries.isEmpty()) ? null : ignoredEntries; _keyType = src._keyType; _valueType = src._valueType; _valueTypeIsStatic = src._valueTypeIsStatic; _valueTypeSerializer = src._valueTypeSerializer; _keySerializer = (JsonSerializer<Object>) keySerializer; _valueSerializer = (JsonSerializer<Object>) valueSerializer; // [databind#2181]: may not be safe to reuse, start from empty _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); _property = property; _filterId = src._filterId; _sortKeys = src._sortKeys; _suppressableValue = src._suppressableValue; _suppressNulls = src._suppressNulls; }
/** * @since 2.5 */ @SuppressWarnings("unchecked") protected MapSerializer(Set<String> ignoredEntries, JavaType keyType, JavaType valueType, boolean valueTypeIsStatic, TypeSerializer vts, JsonSerializer<?> keySerializer, JsonSerializer<?> valueSerializer) { super(Map.class, false); _ignoredEntries = ((ignoredEntries == null) || ignoredEntries.isEmpty()) ? null : ignoredEntries; _keyType = keyType; _valueType = valueType; _valueTypeIsStatic = valueTypeIsStatic; _valueTypeSerializer = vts; _keySerializer = (JsonSerializer<Object>) keySerializer; _valueSerializer = (JsonSerializer<Object>) valueSerializer; _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); _property = null; _filterId = null; _sortKeys = false; _suppressableValue = null; _suppressNulls = false; }
public ReferenceTypeSerializer(ReferenceType fullType, boolean staticTyping, TypeSerializer vts, JsonSerializer<Object> ser) { super(fullType); _referredType = fullType.getReferencedType(); _property = null; _valueTypeSerializer = vts; _valueSerializer = ser; _unwrapper = null; _suppressableValue = null; _suppressNulls = false; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); }
/** * Non-contextual, "blueprint" constructor typically called when the first * instance is created, without knowledge of property it was used via. * * @since 2.6 */ protected AsArraySerializerBase(Class<?> cls, JavaType et, boolean staticTyping, TypeSerializer vts, JsonSerializer<Object> elementSerializer) { super(cls, false); _elementType = et; // static if explicitly requested, or if element type is final _staticTyping = staticTyping || (et != null && et.isFinal()); _valueTypeSerializer = vts; _property = null; _elementSerializer = elementSerializer; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _unwrapSingle = null; }
/** * @deprecated Since 2.6 Use variants that either take 'src', or do NOT pass * BeanProperty */ @Deprecated protected AsArraySerializerBase(Class<?> cls, JavaType et, boolean staticTyping, TypeSerializer vts, BeanProperty property, JsonSerializer<Object> elementSerializer) { // typing with generics is messy... have to resort to this: super(cls, false); _elementType = et; // static if explicitly requested, or if element type is final _staticTyping = staticTyping || (et != null && et.isFinal()); _valueTypeSerializer = vts; _property = property; _elementSerializer = elementSerializer; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _unwrapSingle = null; }
Object readResolve() { if (_member instanceof AnnotatedField) { _accessorMethod = null; _field = (Field) _member.getMember(); } else if (_member instanceof AnnotatedMethod) { _accessorMethod = (Method) _member.getMember(); _field = null; } if (_serializer == null) { _dynamicSerializers = PropertySerializerMap.emptyForProperties(); } return this; }
_serializer = (JsonSerializer<Object>) ser; _dynamicSerializers = (ser == null) ? PropertySerializerMap .emptyForProperties() : null; _typeSerializer = typeSer; _cfgSerializationType = serType;
public MultimapSerializer(MapLikeType type, BeanDescription beanDesc, JsonSerializer<Object> keySerializer, TypeSerializer vts, JsonSerializer<Object> valueSerializer, Set<String> ignoredEntries, Object filterId) { super(type.getRawClass(), false); _type = type; _property = null; _keySerializer = keySerializer; _valueTypeSerializer = vts; _valueSerializer = valueSerializer; _ignoredEntries = ignoredEntries; _filterId = filterId; _sortKeys = false; _dynamicValueSerializers = PropertySerializerMap.emptyForProperties(); }
public HibernateProxySerializer(boolean forceLazyLoading, BeanProperty property) { _forceLazyLoading = forceLazyLoading; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _property = property; }
public HibernateProxySerializer(boolean forceLazyLoading, boolean serializeIdentifier, boolean nullMissingEntities, Mapping mapping, BeanProperty property) { _forceLazyLoading = forceLazyLoading; _serializeIdentifier = serializeIdentifier; _nullMissingEntities = nullMissingEntities; _mapping = mapping; _dynamicSerializers = PropertySerializerMap.emptyForProperties(); _property = property; }