One of my class need to store classes according to their superclasses. To that end, I’m using a HashMap, where keys are the superclasses, and values a list of their extended classes. So it looks like that :
HashMap<Class<?>, List<Class<?>>>
I’d like to know if there was a notation allowing me to be more precise, something like :
HashMap<Class<T>, List<Class<? extends T>>>
I’ve tried that and, of course, it doesn’t work : T cannot be resolved. Is there a syntax that would allow me to do that ? Thanks in advance for your help.
You can do that with accessor methods.