View RSS Feed

Java Array

Java arrays.

  1. Class Objects for Arrays

    by , 03-04-2012 at 11:17 AM
    An associated class object is present for every array that is shared to other arrays along with similar component type.An array’s direct superclass is Object. Interfaces java.io.Serializable and Cloneable are implemented by every array type.

    Following example code could better explain this:
    Java Code:
    class Test {
    	public static void main(String[] args) {
    		int[] ia = new int[3];
    		System.out.println(ia.getClass());
    		System.out.println(ia.getClass().getSuperclass());
    ...
    Tags: object array Add / Edit Tags
    Categories
    Object Array