Let's take the Class class. It is not a container, so it is not evident from the first sight, why do we have a parameter here. You start getting "Class is a raw type. References to generic type Class
The best answer to such questyions is to look at the source code, and find references to the parameter. Almost instantly you'll see, that the newInstance() method returns now T, which gives us a very powerful premise to create object factories with strong typing. Like this:
public static <T> Collectionselect(Class<T> c, int times) {
Collection<T> result = new ArrayList<T>();
for (int i=0; i<times; i++) {
T item = c.newInstance();
result.add(item);
}
return result;
}
This example is oversimplified, but you should already see, what a gift we've got here!