The question is about the Java class SimpleDateFormat. I read in the documentation that
Date formats are not synchronized. It is recommended that you create separate format instances for each stream. If several threads access the format at the same time, it must be synchronized from the outside.
Obviously, I read that after he got into the most obscure way.
Does anyone know why it is necessary to have state information in classes accessed by the format method?
Is this speed optimization? I can’t find a good reason.
Your answer pretty much lies here:
/* * (C) Taligent, Inc. 1996 -
1.4 hotspot Java . 10 - , (- ) .
1996 Garbage Collection , , , , , , ( , Windows 95 4 L2 .....).
, , , ( , , 486 Pentium 1 8 4 ....), , - .
, , , .
100% - , , !
, . .
, : SimpleDateFormat Java ?