Archives for July, 2008
Class>.cast(..) and Generics - a powerful combination
Saturday, July 12th, 2008
As you know when it comes to casting a la Java 1.4 a developer will have to write, typically, something like this:
Object a = "iron man";
String b = (String)a;
Well, there is nothing wrong with this code. However, it is not pretty :). With Java 5.0 the casting mechanism is more explicit and nicer. [...]