Results 1 to 1 of 1
-
Getting methods of a Class - Reflection
Using Reflection, we can get all the methods of a class. Review the following code:
Array of type Method named myArray hold all the methods.Java Code:Class c = Class.forName("Countries"); Method mArray[] = c.getDeclaredMethods(); for(Method m: mArray) System.out.println(m.getName());
Similar Threads
-
Abstract Class with Static Methods
By bugger in forum New To JavaReplies: 7Last Post: 09-05-2008, 12:20 AM -
Getting class field information using Reflection
By Java Tip in forum Java TipReplies: 0Last Post: 01-24-2008, 03:20 PM -
Execution methods – Reflection
By Java Tip in forum Java TipReplies: 0Last Post: 11-15-2007, 03:19 PM -
Mocking static methods of class
By Kat in forum New To JavaReplies: 3Last Post: 11-08-2007, 12:24 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks