0
Help us understand the problem. What are the problem?

posted at

Javaでnullのフィールドをレスポンスに表示

調べてもすぐ出てこなかったのでメモ。

表示させないようにするのはこちらですが…

@JsonInclude(JsonInclude.Include.NON_EMPTY)

nullや空文字でも表示させたいときはこう書く。

@JsonInclude(JsonInclude.Include.ALWAYS)

Register as a new user and use Qiita more conveniently

  1. You can follow users and tags
  2. you can stock useful information
  3. You can make editorial suggestions for articles
What you can do with signing up
0
Help us understand the problem. What are the problem?