FileDocCategorySizeDatePackage
ListMethods.javaAPI DocExample743Sun Feb 08 21:33:52 GMT 2004None

ListMethods

public class ListMethods extends Object
List the Constructors and methods
author
Ian F. Darwin, http://www.darwinsys.com/
version
$Id: ListMethods.java,v 1.3 2004/02/09 03:33:51 ian Exp $

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] argv)

		if (argv.length == 0) {
			System.err.println("Usage: ListMethods className");
			return;
		}
		Class c = Class.forName(argv[0]);
		Constructor[] cons = c.getConstructors();
		printList("Constructors", cons);
		Method[] meths = c.getMethods();
		printList("Methods", meths);
	
static voidprintList(java.lang.String s, java.lang.Object[] o)

		System.out.println("*** " + s + " ***");
		for (int i=0; i<o.length; i++)
			System.out.println(o[i].toString());