I think there's something more to say and there are some corrections to made to "Bessa"'s reply.
"Please, could you allocate some more memory and put my object there ?"
Actually this is not 100% correct. When creating an array of objects, it doesnt requst to allocate some more memory and put the objects into it. What it does is, it request the JVM to allocate an array which we can hold references to the given type of objects. Array just hold the reference of the object, and the object exists in a seperate location..
int x = 9;
int[] dots = {3,6,x,8};
x is not an reference. as long as x is a primitive variable, x is copying it's value to the array and it doesnt called a reference variable.
[ February 13, 2006: Message edited by: Roshan Amadoru ]