On 8/29/07, Paolo Denti <[EMAIL PROTECTED]> wrote: > > Kevan, i tried and following the execution, the problem is in the > proxyManagerClass.getMethod("createProxy", clzArray); > the getMethod call fails. > > But looking at the javadoc i see that the signature of the ProxyManager > createProxy method is > > Object *createProxy*(javax.management.ObjectName, Class) > > but we are inovoking proxyManagerClass.getMethod("createProxy", clzArray) > where clzArray is a Class[] as if the signature were > > Object *createProxy*(javax.management.ObjectName, Class[]) > > Hi Paolo,
the getMethod() takes 2 parameters: 1) the method name 2) the method parameter Classes in the form of Class[]. clzArray contains {ObjectName.class,Class.class} as the createProxy() signature is defined. I think you are confusing the createProxy() method with the getMethod() method that is part of java.lang.Class. *Method getMethod<http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Class.html#getMethod%28java.lang.String,%20java.lang.Class%5B%5D%29> *(String <http://java.sun.com/j2se/1.4.2/docs/api/java/lang/String.html> name, Class <http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Class.html> [] parameterTypes). I will keep looking into why the getMethod error fails. Is there a stack trace or error message? -Viet