@John Meyers
Before I have posted this, I have looked at
this errata and this is not on the list. Is there any new errata list ?
@Bhushan Chhajed
Arrays and Collections are utility classes and they must mark their api methods as public to be accessible by any class. Don't mistake utility classes with interfaces, where you don't have to type public abstract in front of the methods. I have looked even in the source code of the JDK(I'm using 1.5.0_15) and of course the methods are marked public.
Another little typo is on the page 610:
The generics type identifier can be used in class, method, and variable declarations:
class Foo<t> { } // a class
T anInstance; // an instance variable
Foo(T aRef) {} // a constructor argument
void bar(T aRef) {} // a method argument
T baz() {} // a return type
The compiler will substitute the actual type.
"t" must be "T"
[ July 06, 2008: Message edited by: Marte Marte ]
[ July 06, 2008: Message edited by: Marte Marte ]
[ July 06, 2008: Message edited by: Marte Marte ]