How to create reflection class in java and is there any possible way to pass more than two class as argument -


i'm trying pass more 2 class in code given below

getmethod(methodname, new class[] { rootbean.getclass() }) 

and want create object argument class can call method of arugment class.

if(obj==null) {      classa.getmethod((methodname, new class[] { rootbean.getclass() })); } else {     // other operation } 

you

getmethod(methodname, new class[] { rootbean.getclass(), otherbean.class }); 

however class#getmethod takes variable length argument, no need create array, pass class agrument separated comma

getmethod(methodname, rootbean.getclass(), otherbean.class); 

Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -