SI
SI
discoversearch

We've detected that you're using an ad content blocking browser plug-in or feature. Ads provide a critical source of revenue to the continued operation of Silicon Investor.  We ask that you disable ad blocking while on Silicon Investor in the best interests of our community.  If you are not using an ad blocker but are still receiving this message, make sure your browser's tracking protection is set to the 'standard' level.
Technology Stocks : All About Sun Microsystems -- Ignore unavailable to you. Want to Upgrade?


To: David W. Ricker who wrote (15924)4/29/1999 10:56:00 AM
From: Mike Milde  Read Replies (1) | Respond to of 64865
 

Where I work we've done extensive Y2K testing on all our software, including the Sun boxes running Solaris and Java code. Everything from Sun is Y2K compliant so far.

But this sample code from that Java book is a bad example of good coding practices.

Mike



To: David W. Ricker who wrote (15924)4/29/1999 11:07:00 AM
From: Mike Milde  Read Replies (1) | Respond to of 64865
 
Wrong Ricker. That code is Y2K compliant. I just checked the API. Date.getYear() returns the # of years since 1900, so this works just fine the way it is written.

I think you might have assumed that Java uses a two digit year in its Date class.

Mike



To: David W. Ricker who wrote (15924)4/29/1999 11:46:00 AM
From: Stormweaver  Respond to of 64865
 
David your wrong on that one. The methods your talking about have been deprecated in the Date class since JDK 1.1.5. I have successfully tested and ran my date sensitive java app in a post 2000 environment without trouble; on Solaris 2.5.1.