When dealing with multiple instances of the object type, an array of object types can be defined. Defining an array of objects simplifies data management when sending the information to the different objects.
Sometimes there is a need to maintain lists of objects. An example could be the display of a histogram of stocks. Each Viz object is attributed a DataPool object. But in this case, it would be very unwise to give a name to each of the objects because the number of the objects may be unknown. DataPool solves this problem by providing with a means of array of objects. Like in the case of the single object, the array has an object type. When defined the array builds a set of objects as its children. This scheme is shown in the following figure:
In the figure, an array of stocks of size four is shown. As can be seen each of its children are named Stocks, Stocks, and so on. To enter data to the array element number 2:
If we want to enter information to the whole array:
Note: There are two sets of brackets in the above statement: One for the array itself and a second for the objects themselves. Also note that because this is an array, the objects are separated by commas rather than by semicolons.