Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
列挙型があるとします。
@Enumerated(EnumType.STRING) private Gender gender;
jackson json パーサーは json 文字列からこの値を設定できますか?
はい。これを確認する 1 つの方法は、POJO 値をシリアル化して、何が起こるかを確認することです。デフォルトでは、enum.name() がシリアル化として使用され、逆シリアル化に使用されます。