Class PDTFormatter.LocalizedDateFormatCache

All Implemented Interfaces:
ICache<PDTFormatter.CacheKey,DateTimeFormatter>, IMutableCache<PDTFormatter.CacheKey,DateTimeFormatter>, IHasSize, IHasName
Enclosing class:
PDTFormatter

@ThreadSafe public static final class PDTFormatter.LocalizedDateFormatCache extends Cache<PDTFormatter.CacheKey,DateTimeFormatter>
This class caches the compiled patterns for localized date and time formatter. Using e.g. DateTimeFormatter.ofLocalizedDate(java.time.format.FormatStyle) is not an option because the used "year of era", corresponding to pattern "y" makes problems. Instead "year" with the pattern "u" must be used for best backwards compatibility.
Author:
Philip Helger