-
-
Notifications
You must be signed in to change notification settings - Fork 703
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
Internal limitation or big code-18? #65
Comments
Additional info it it matters: if I scan for Object.class I get ~6510 classes and all my 446 TOs are in there. Could the issue be with Interfaces and/or Serializable itself? |
This is a familiar behavior, still, not well understood and might be a code-18 - let me know what you think: There's a missing link from Module to AbstractModule, and this breaks transitivity. The reasons/solutions might vary:
|
Ok, so any parent class of a class outside of the scanning scope might not be know to Reflection; if I find time I will try to test this with a small scale experiment. Could be a good idea to document that behavior in the javadoc for getSubTypesOf(). Could also be a nice additional option for SubTypesScanner; letting it scan everything, but only use the package as a way to filter out the final results. For us, performance isn't that big of a deal right now since we use Reflection mainly for system-wide "integration" testing (we scan for common mistakes). I will try scanning the wider "my.project", but post-filter-out results that aren't in the package I want to scan to see if indeed it would be a viable workaround. |
Not sure if I'm doing something wrong of of there is some kind of technical limitation to what Reflections can do, I get very weird results when using the API; I have an Interface, TO that extends Serializable (and does nothing else, no extra methods, nothing), but when I scan for Serializable, I don't seem to get all the TOs, far from it:
TO is actually in another package than the one I'm scanning and the project is quite large. Using (old) Java 6 on Windows if it matters; and yes I tried to do the intersection manually to make sure the Apache Commons lib didn't contain a bug.
Bug, limit, code-18, what is happening here?
The text was updated successfully, but these errors were encountered: