I would like to know if there is an easy way to retrieve the first date encountered from String in Java.
My program will analyze many String texts in different languages. These lines may contain a date . Due to the languages (and different sources) I have so many formats to consider.
I first thought of Regex , creating one regex for each format I could find ... But there are a lot, like "Month (d) d, yyyy" or "mm / dd / yyyy" or "dd-mon- yyyy "...
So, I wanted to know if there is an easier way to extract the date from String, possibly using DateFormat, so I can convert the found date to "dd / mm / yyyy".
Thank you for your help. ^^
Malik source
share