I have the following two dates:
- 8 Oct. 2009
- 13 May 2010
I am using Jackson to convert the date from an rest api to joda Datetime.
I thought the pattern "dd MMM. yyyy"
would work but the "may" has no dot so it crashes at that point.
Is there a solution or do I have to write my own datetime parser?
The annotation in jackson is:
@JsonFormat(pattern = "dd MMM. yyyy", timezone = "UTC", locale = "US", )
@JsonProperty(value = "date")
private DateTime date;
So there is only one date pattern allowed.
See Question&Answers more detail:os