Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

I want to check if a class is a subclass of some other class

807580Mar 22 2009 — edited Aug 29 2010
Hi All,

I wan to implement something like;

if (sMethod.getReturnType() is a subclass of+ A.class) // if sMethod returns a class that is subclass of A class //then do this;

Can anyone please help me on this?


Kind Regards.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 26 2010
Added on Mar 22 2009
7 comments
605 views