java - How to use getMethod() with primitive types? -


this class:

class foo {   public void bar(int a, object b) {   } } 

now i'm trying "reflect" method class:

class c = foo.class; class[] types = { ... }; // should here? method m = c.getmethod("bar", types); 

there's int.class.

class[] types = { int.class, object.class }; 

an alternative integer.type.

class[] types = { integer.type, object.class }; 

the same applies on other primitives.


Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -