Originally posted by Paul Villangca:
I think it's because you can't cast arrays of objects.
TC and RC are reference types and type RC can be cast to TC by a recursive application of these run-time rules for casting.
If T is a class type, then R must be either the same class (�4.3.4) as T or a subclass of T, or a run-time exception is thrown.
If T is an interface type, then R must implement (�8.1.4) interface T, or a run-time exception is thrown.
SCJP2. Please Indent your code using UBB Code
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime. |