Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: getAllMethods returns all methods, incl. those of libraries and java.lang.Object #771

Merged
merged 1 commit into from
Aug 10, 2016

Conversation

monperrus
Copy link
Collaborator

thanks to the new and great runtime reflection API, we can have at last a correct implementation of getAllMethods


CtTypeReference<?> superclass = type.getSuperclass();
Assert.assertEquals(ExtendsObject.class.getName(), superclass.getQualifiedName());

Assert.assertEquals(ExtendsObject.class.getName(), superclass.getQualifiedName());

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@msteinbeck
Copy link
Contributor

Does this include methods of libraries not available in classpath?

@GerardPaligot
Copy link
Contributor

@ReTuXx Yes. CtTypeReference#getTypeDeclaration uses the Java API reflexion to get all structural elements of external classes.

@tdurieux
Copy link
Collaborator

@GerardPaligot you are wrong if the class is not in the classpath the reflexion does not work...

@monperrus monperrus force-pushed the bug-getAllMethods branch from 6a36ca7 to 1f645cd Compare July 29, 2016 13:07
@monperrus monperrus changed the title fix: getAllMethods returns all methods, incl. those of libraries and jav.lang.Object fix: getAllMethods returns all methods, incl. those of libraries and java.lang.Object Jul 29, 2016
@GerardPaligot GerardPaligot merged commit 4e24531 into INRIA:master Aug 10, 2016
@tdurieux tdurieux mentioned this pull request Sep 19, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants