Replies: 2 comments 4 replies
-
|
There is field called @JsonTypeInfo(
use=JsonTypeInfo.Id.CLASS,
include=JsonTypeInfo.As.PROPERTY,
property="@class"
) |
Beta Was this translation helpful? Give feedback.
4 replies
-
|
There isn't anything automatic, but often |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
When using
@JsonTypeInfoannotationpropertyparameter is used specify which exact JSON field is used to determine which exact class will be used. Let's say for example this field is namedtype.However class that uses this annotation on one of it's fields is used by two different
ObjectMappers with different naming conventions set. In one naming convention this JSON field is namedtypein otherType.Is it possible make
@JsonTypeInfobe naming convention aware so right JSON field is used depending which naming convention is set onObjectMapper?If not is there any other way to achieve what
@JsonTypeInfodoes so both JSON naming conventions will work correctly?Regards
Beta Was this translation helpful? Give feedback.
All reactions