I am looking for a java library that can parse a string in POJO without specifying a format. I researched POjava . Is there any other library that does this?
DateTime dateTime = DateTimeParser.parse("21/02/13");
I found the following links with the same problem. Intelligent date / time parser for Java , but not very useful answers. Neither Joda nor Ya Chronik do what I wanted. Correct me if I am wrong.
Update:
The reason I say that Joda does not solve my goal, Joda expects the string to be parsed in the ISO8601 format or in any format that you specify as "yyyyMMdd". I will not hard code this format, since I need to handle several formats.
I have a solution to disambiguate regarding date formats in the USA or Europe, i.e. mm / dd / yy or dd / mm / yy. Assuming I have access to the time zone of a date, can I determine if this is an American or European format? Can someone tell me how to do this? Googled, but found nothing.
source share