Home » openjdk-7 » sun » swing » [javadoc | source]
public class: AccessibleMethod [javadoc | source]
A utility for accessing and invoking methods, via reflection, that would otherwise be unaccessible.
 public AccessibleMethod(Class klass,
    String methodName,
    Class paramTypes) throws NoSuchMethodException 
    Construct an instance for the given params.
    klass - the class to which the method belongs
    methodName - the name of the method
    paramTypes - the paramater type array
    NullPointerException - if klass or name is null
    NoSuchMethodException - if the method can't be found
Method from sun.swing.AccessibleMethod Summary:
invoke,   invokeNoChecked
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from sun.swing.AccessibleMethod Detail:
 public Object invoke(Object obj,
    Object args) throws IllegalArgumentException, InvocationTargetException 
    Invoke the method that this object represents. Has the same behavior and throws the same exceptions as java.lang.reflect.Method.invoke with one exception: This method does not throw IllegalAccessException since the target method has already been made accessible.
 public Object invokeNoChecked(Object obj,
    Object args) 
    Invoke the method that this object represents, with the expectation that the method being called throws no checked exceptions.

    Simply calls this.invoke(obj, args) but catches any InvocationTargetException and returns the cause wrapped in a runtime exception.