Skip to content

Commit b4239d4

Browse files
committed
Merge branch '3.x' of github.com:FasterXML/jackson-databind into 3.x
2 parents ac7c35b + f293824 commit b4239d4

File tree

1 file changed

+0
-42
lines changed

1 file changed

+0
-42
lines changed

src/main/java/tools/jackson/databind/deser/jdk/UntypedObjectDeserializerNR.java

Lines changed: 0 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -353,48 +353,6 @@ protected Object _deserializeFP(JsonParser p, DeserializationContext ctxt)
353353
}
354354
return p.getDoubleValue();
355355
}
356-
357-
// NOTE: copied from above (alas, no easy way to share/reuse)
358-
// @since 2.12 (wrt [databind#2733]
359-
protected Object _mapObjectWithDups(JsonParser p, DeserializationContext ctxt,
360-
final Map<String, Object> result, String initialKey,
361-
Object oldValue, Object newValue, String nextKey)
362-
throws JacksonException
363-
{
364-
final boolean squashDups = ctxt.isEnabled(StreamReadCapability.DUPLICATE_PROPERTIES);
365-
366-
if (squashDups) {
367-
_squashDups(result, initialKey, oldValue, newValue);
368-
}
369-
370-
while (nextKey != null) {
371-
p.nextToken();
372-
newValue = deserialize(p, ctxt);
373-
oldValue = result.put(nextKey, newValue);
374-
if ((oldValue != null) && squashDups) {
375-
_squashDups(result, nextKey, oldValue, newValue);
376-
}
377-
nextKey = p.nextName();
378-
}
379-
380-
return result;
381-
}
382-
383-
// NOTE: copied from above (alas, no easy way to share/reuse)
384-
@SuppressWarnings("unchecked")
385-
private void _squashDups(final Map<String, Object> result, String key,
386-
Object oldValue, Object newValue)
387-
{
388-
if (oldValue instanceof List<?>) {
389-
((List<Object>) oldValue).add(newValue);
390-
result.put(key, oldValue);
391-
} else {
392-
ArrayList<Object> l = new ArrayList<>();
393-
l.add(oldValue);
394-
l.add(newValue);
395-
result.put(key, l);
396-
}
397-
}
398356

399357
/*
400358
/**********************************************************************

0 commit comments

Comments
 (0)