permaculture playing cards*
The moose likes Java in General and the fly likes Is it possible to invoking a method by getting its name in string... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Is it possible to invoking a method by getting its name in string..." Watch "Is it possible to invoking a method by getting its name in string..." New topic
Author

Is it possible to invoking a method by getting its name in string...

Pankaj Mittal
Ranch Hand

Joined: Jul 09, 2008
Posts: 32
I want to invoke a method whose name I've got in string.....


2008 SCJP(5.0) 88%
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

You can do this sort of thing via Reflection. Have a read though that link it should set you on your way.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Pankaj Mittal
Ranch Hand

Joined: Jul 09, 2008
Posts: 32
Thanks buddy !!
I found the solution...

 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Is it possible to invoking a method by getting its name in string...
 
Similar Threads
Not able to run sample servlet + jsp
Checking for null inputs
Confusion with the below mentioned code
need help urgently
javax.jms.Message method