Greetings, Using java reflection, you can obtain a reference to a Method object and use that Method object to invoke the method.
Also, using reflection, you can create and work with arrays without knowing the type of the array at compile time. Check out ... * getMethod(...) and getMethods() methods on the java.lang.Class class * java.lang.reflect.Method * java.lang.reflect.Array Louis W. Lembcke, Principal Chicago Systems Group 180 N. Stetson, Suite 3200 Chicago, IL 60601 USA Main Tele: +1 312.444.2760 Facsimile: +1 425.969.6391 mailto:[EMAIL PROTECTED] http://www.ChicagoSystemsGroup.com/ -----Original Message----- From: Panagiotis Plevrakis [mailto:[EMAIL PROTECTED]] Sent: Sunday, May 05, 2002 2:43 PM To: JDJList Subject: [jdjlist] RE: Arays Methods are not objects or primitive types. Arrays can hold only objects and primitive types. You can only save your methods in an array of Strings if you can do something useful with them later: String methods[] = new String[]{ "public void name(){}", "public void name(){}"}; The only reason that comes in my head for doing that is for some code generator program. Panos _________________________________________________________________ Chat with friends online, try MSN Messenger: http://messenger.msn.com To change your membership options, refer to: http://www.sys-con.com/java/list.cfm To change your membership options, refer to: http://www.sys-con.com/java/list.cfm
