Updated the CSR based on your inputs.
On 1/27/22 2:34 PM, Stephen Colebourne wrote:
On Thu, 27 Jan 2022 at 19:23, Naoto Sato <naoto.s...@oracle.com> wrote:
Now come to think of it, I came up with the draft based on `ofPattern()`
methods. One of them is a overload method that takes a Locale argument.
Why is it so?
There is a case for the Locale on the static method (as a convenience,
and to remind callers that the locale matters). But there is no case
for it on the builder.
Eliminated the overload with locale. Instead, added a static method
DateTimeFormatterBuilder.getLocalizedDateTimePattern() that take
"requestedTemplate". Also, renamed `appendLocalizedPattern` to
`appendLocalized` to make it an overload method to the existing one.
The spec Javadoc doesn't explain what repeating the pattern letter
actually does/means. Is "M" the same as "MMMM"?
That depends on the locale and the availability of the formats. For
example, 'M' translates into these patterns in each locale with
Gregorian calendar:
https://unicode-org.github.io/cldr-staging/charts/40/by_type/date_&_time.gregorian.html#959cbb42bb2962f
As things stand, the Javadoc isn't a standalone spec. I don't know how
much that matters, but I think there should be some indication in
Javadoc as to why the letter should be repeated.
Added a description that explains the number of pattern letters. They
follow the same presentation rule as in the pattern chart.
Naoto