In an attempt to see if I can clean up some of my math code, mostly matrix stuff, I am trying to use some Java Generics. I have the following method:
private <
Arrays and Generics do not play well together:
"Arrays are covariant, which means that an array of supertype references is a supertype of an array of subtype references. That is, Object[]
is a supertype of String[]
and a string array can be accessed through a reference variable of type Object[]
."
see the Java Generics FAQ: