RFR: Add value-type notice to java.time classes
Stephen Colebourne
scolebourne at joda.org
Thu Dec 5 11:04:33 UTC 2013
Pretty much looks good.
However, I notice that the equals, hashCode and toString methods of
the 4 calendar specific date classes are inherited rather than
written. Without additional spec, I'm not sure that they can claim to
be value types. Adding the 12 Javadocs should be relatively easy.
JapaneseEra should also be a value type, but it needs Javadoc and an
implementation of equals and hashCode that check state.
The chronology classes are potential value types, but as they are
generally singletons, perhaps it matters less.
Stephen
On 4 December 2013 21:08, roger riggs <roger.riggs at oracle.com> wrote:
> Corrected.
>
> Thanks, Roger
>
>
> On 12/4/2013 3:42 PM, Xueming Shen wrote:
>>
>> On 12/04/2013 12:00 PM, roger riggs wrote:
>>>
>>> Following the lead of the notices added to Optional, the java.time value
>>> based
>>> classes should include the same notice.
>>>
>>> Please review:
>>> http://cr.openjdk.java.net/~rriggs/webrev-time-valuetype-8029551/
>>>
>>> Thanks, Roger
>>>
>>>
>>
>>
>> http://cr.openjdk.java.net/~rriggs/webrev-time-valuetype-8029551/src/share/classes/java/time/ZonedDateTime.java.sdiff.html
>>
>> LD -> ZDT
>
>
More information about the core-libs-dev
mailing list