I would like to determine if an object is an instanceof a generic type. How may I do this?
something like if (someVariable instanceof E){}
Thanks!
EDIT
I think I found an answer: if (getClass() != obj.getClass()) {return false;}
I would like to determine if an object is an instanceof a generic type. How may I do this?
something like if (someVariable instanceof E){}
Thanks!
EDIT
I think I found an answer: if (getClass() != obj.getClass()) {return false;}
This is not possible due to type erasure.