How to retrieve the parameterized type of a Collection object?

For example:

List<Integer> abc = new ArrayList<Integer>();

What java reflection API(s) for retrieving the parameterized type of the above collection object? (i.e. Integer).
zollenAsked:
Who is Participating?
 
a_bCommented:
Have a look the code posted by this person - http://blog.demay-fr.net/index.php/2007/08/30/77-get-the-genereric-type-of-a-generic-class

Look at the end of the page.
0
 
Gurvinder Pal SinghCommented:
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.