Post
원문 보기 →Jackson @JsonFormat Example
JsonFormat.Shape.STRINGWhen we assign JsonFormat.Shape.STRING to shape attribute in @JsonFormat for a property, suppose Date type, then in serialization JSON will be string type in given pattern for that property.public class Writer { @JsonFormat(shape=JsonFormat.Shape.STRING, pattern="yyyy-MMM-dd HH:mm:ss z") @JsonProperty("pubDate") private Date recentBookPubDate;} Output will be as foll



