Name: nt126004 Date: 09/28/2001
java version "1.4.0-beta2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta2-b77)
Java HotSpot(TM) Client VM (build 1.4.0-beta2-b77, mixed mode)
The following example should return "0" as mentioned in the Java API
Documentation for java.lang.Class.getMethods():
-- extracted from documentation:
This method returns an array of length 0 if this Class object represents a class
or interface that has no public member methods, or if this Class object
represents an array class, primitive type, or void.
---
public class test
{
public static void main(String[] args) {
System.out.println(args.getClass().getMethods().length);
}
}
=> returns 9 (all inherited Methods from java/lang/Object).
(Review ID: 132553)
======================================================================