How to use FastDateFormat to create a Date object using String

I used SimpleDataFormat, and it seems this is not a very safe thing for the ceiling. Then I discovered that FastDateFormat is an alternative to this problem. But I'm trying to figure out how to use it to parse a String with a date and time.

Here is an explanation why the misuse of SimpleDateFormat is bad: Why is SimpleDateFormat for Java not thread safe?

The problem is in the code: I have a line

String date = "2014-04-27'T'13:45:31";

I need to convert this to Date. But in streaming mode. I would like to use something related to FastDateFormat. NotSimpleDateFormat

+4
source share
1

, commons-lang 3.2.

:

.

+4

All Articles