mercredi 22 juin 2016

Is there a way to know what Types are implemented in child object using reflection

I have a super class

class A<X,Y,Z> {
}

Then I have the child class B (P, Q, R are another set of classes)

class B extends A<P,Q,R> {
}

in my JUnit test case I want to know the classes P,Q,R when given an object B. Is this possible using reflection?





Aucun commentaire:

Enregistrer un commentaire