// classname including internal names for anonymous classes used in serialization import java.util.Collection; import java.util.ArrayList; import java.util.AbstractList; ... out.println( String.class ); // java.lang.String out.println( int.class ); // int out.println( int[].class ); // [I out.println( Integer[].class ); // [Ljava.lang.Integer; out.println( double.class ); // double out.println( Double.class ); // java.lang.Double out.println( Double.TYPE ); // double AbstractList p = new ArrayList(); out.println( p.getClass() ); // java.util.ArrayList not AbstractList String[] s = new String[10]; out.println( s.getClass().getComponentType() ); // java.lang.String