Author(s)Craig R. McClanahan, Ralph Schaer, Chris Audley, Rey Fran�ois, Gregor Ra�man, Jan Sorensen, Robert Burrell Donkin
Utility reflection methods focussed on methods in general rather than properties in particular.
Known Limitations
Accessing Public Methods In A Default Access Superclass
There is an issue when invoking public methods contained in a default access superclass.
Reflection locates these methods fine and correctly assigns them as public.
However, an IllegalAccessException is thrown if the method is invoked.
MethodUtils contains a workaround for this situation.
It will attempt to call setAccessible on this method.
If this call succeeds, then the method can be invoked as normal.
This call will only succeed when the application has sufficient security privilages.
If this call fails then a warning will be logged and the method may fail.
Utility reflection methods focussed on methods in general rather than properties in particular.
Known Limitations
Accessing Public Methods In A Default Access Superclass
There is an issue when invoking public methods contained in a default access superclass. Reflection locates these methods fine and correctly assigns them as public. However, an
IllegalAccessExceptionis thrown if the method is invoked.MethodUtilscontains a workaround for this situation. It will attempt to callsetAccessibleon this method. If this call succeeds, then the method can be invoked as normal. This call will only succeed when the application has sufficient security privilages. If this call fails then a warning will be logged and the method may fail.