Originally posted by Shiaber Shaam:
I don't know what do you mean by <Thing> in the above statements.
It's the use of
Java 1.5 generics and it's perfectly legal.
But, the code should be as shown below,
No, the code statements are fine.
The problem is that these statements do not appear within a method or initializer block. That's not valid. The code needs to appear inside a code container.