[threeten-dev] Add standalone text styles

Roger Riggs Roger.Riggs at Oracle.com
Tue Mar 5 21:04:46 PST 2013


Hi,

Thanks for the comments.

On 03/05/2013 10:31 PM, Masayoshi Okutsu wrote:
> Here are my comments.
>
> - LDML (UTS#35) calls non-stand-alone styles format styles (forms) 
> rather than normal styles. I prefer to follow the LDML naming.
Updated to use CLDR friendly terminology.
>
> - I suspect that it's hard for most developers to understand the 
> differences between the "normal" and stand-alone constants from the 
> descriptions. The examples are the same ones, like "Monday".
The explanation can be expanded with more examples.
>
> - It happens to work if you use DateFormat styles as an index to the 
> time zone names array. But it's not correct to use DateFormat styles.
I could not checkin something that didn't work. I replaced the 
DateFormat references with literals.
But it was quite unclear where the values were defined in the 
implementation.
There was some very brittle code dependent on the enum values.
>
> - TBD part: Calendar defines both format and standalone styles to 
> which the TextStyles need to map.
>
> If you add the standalone constants to TextStyle, I can take care of 
> the rest.
ok,  I'll push, but there may still be some additional comments about 
the public API.

Roger

>
> Masayoshi
>
> On 3/6/2013 6:32 AM, roger riggs wrote:
>> Please review this addition to add TextStyle enum values for 
>> standalone versions
>> of FULL, SHORT, NARROW to support CLDR defined patterns.
>>
>> http://cr.openjdk.java.net/~rriggs/webrev-addstandalone/
>>
>> More work is needed after the public API is defined.
>>
>> Thanks, Roger
>>
>



More information about the threeten-dev mailing list