Skip to content

Commit

Permalink
Apply review
Browse files Browse the repository at this point in the history
  • Loading branch information
JooHyukKim committed May 22, 2023
1 parent 1966d6c commit 7f116b5
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1510,8 +1510,7 @@ protected TypeResolverBuilder<?> _findTypeResolver(MapperConfig<?> config,
Annotated ann, JavaType baseType)
{
// since 2.16 : backporting {@link JsonTypeInfo.Value} from 3.0
final AnnotationIntrospector ai = config.getAnnotationIntrospector();
JsonTypeInfo.Value typeInfo = ai.findPolymorphicTypeInfo(config, ann);
JsonTypeInfo.Value typeInfo = findPolymorphicTypeInfo(config, ann);

// First: maybe we have explicit type resolver?
TypeResolverBuilder<?> b;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,16 +103,19 @@ public TypeDeserializer buildTypeDeserializer(DeserializationConfig config,
* Initialization method that is called right after constructing
* the builder instance, in cases where information could not be
* passed directly (for example when instantiated for an annotation)
* <p>
* NOTE: This method will be abstract in Jackson 3.0.
*
* @param settings Configuration settings to apply.
*
* @return Resulting builder instance (usually this builder,
* but not necessarily)
*
* @since 2.16
*
* @since 2.16 (backported from Jackson 3.0)
*/
public T init(JsonTypeInfo.Value settings, TypeIdResolver res);

default T init(JsonTypeInfo.Value settings, TypeIdResolver res) {
return init(settings.getIdType(), res);
}

/*
/**********************************************************
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,6 @@ public void testUnWrappedMapWithDefaultType() throws Exception{
assertEquals("{\"@type\":\"HashMap\",\"xxxB\":\"bar\"}", json);
}

// [databind#838]
public void testUnWrappedMapWithDefaultTypeWithValue() throws Exception {
final ObjectMapper mapper = new ObjectMapper();
SimpleModule mod = new SimpleModule("test");
Expand Down

0 comments on commit 7f116b5

Please sign in to comment.