Additional Testing
I did some additional testing. Here's what I discovered. If I do this:
Dim x as list
Dim y as list
x.addall(array as string("1","2"))
y.addall(x)
The x and y variables display like this in the debugger:
x (ArrayList) [1,2]
y (ArrayList) [1,2]
But if I do this:
Dim x as list
Dim y as list
Dim z as list
x.addall(array as string("1","2"))
y.addall(array as string("1","2"))
z.add(x)
z.add(y)
Then the debugger displays x and y as before but z as:
z (ArrayList) [[1,2],[1,2]]
So in the first instance it appears that y is an array of strings. In the second instance z is an array of list objects. That seems like inconsistent behavior. In my case, since I don't know how many records I have in the database, I need a way to always have an array of objects. Is there some other way to do that?