[jboss-jira] [JBoss JIRA] Created: (JBREFLECT-33) Optimize away NoSuchXXXExceptions from ReflectionUtils
Adrian Brock (JIRA)
jira-events at lists.jboss.org
Wed Aug 13 11:21:40 EDT 2008
Optimize away NoSuchXXXExceptions from ReflectionUtils
------------------------------------------------------
Key: JBREFLECT-33
URL: https://jira.jboss.org/jira/browse/JBREFLECT-33
Project: JBoss Reflection
Issue Type: Task
Components: ClassInfo
Reporter: Adrian Brock
Assignee: Adrian Brock
Fix For: JBossReflection.2.0.0.CR1
Having removed some unnecessary NoSuchMethodExceptions in JBMDR-28
I reintroduced some others in JBMDR-29 when I made it use ReflectionUtils.
The issue is that ReflectionUtils should not use:
try
{
method = Class.getDeclaredMethod();
}
catch (NoSuchMethodException ignored) {}
which creates a lot of exceptions when searching for methods in super classes.
Instead we should iterate over Class.getDeclaredMethods() and match the name/parameters ourselves.
This is pretty much what Class.getDeclaredMethod() does anyway.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list