[concurrency-interest] Re: AtomicInteger and AtomicLong should implement Number

Joshua Bloch joshua.bloch@sun.com
Fri, 09 Jan 2004 00:29:50 -0500


Gregg,

>
> A big thrust of jdk1.5 is programmer friendliness.  Things are 
> supposed to be easier to do.  Having to spray
>
>     new Integer( atomicIntForSomeUse.get() )
>
> all over the place, doesn't make the job any easier.

You don't have to.  Autoboxing does most of the work for you.  (You do 
need to say "get()," but not "new Integer()".)

     Regards,

     Josh