# Objects to hold data

**URL:** <https://forum.kirupa.com/t/objects-to-hold-data/159003>\
**Category:** Uncategorized\
**Created:** [August 13, 2005, 6:05pm UTC](https://forum.kirupa.com/t/objects-to-hold-data/159003 "2005-08-13T18:05:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chapster](https://avatars.discourse-cdn.com/v4/letter/c/958977/32.png) [@chapster](https://forum.kirupa.com/u/chapster)\
**Post date:** [August 13, 2005, 6:05pm UTC](https://forum.kirupa.com/t/objects-to-hold-data/159003/1 "2005-08-13T18:05:11Z")

</div>

I saw this code that runs through xml and there was one part that I didn’t understand.

```auto

var rootNode:XMLNode= this.firstChild;
var len:Number = rootNode.childNodes.length;

for(var i:Number=0; i<len; i++){
  var o:Object = new Object();
  o.label = rootNode.childNodes*.attributes.label;
  trace(o.label + "(" + i + ")");
  var len2:Number = rootNode.childNodes*.childNodes.length;

  for(var j:Number=0; j<len2; j++){
    var node:String = rootNode.childNodes*.childNodes[j].nodeName;
    var nodeValue:XMLNode = rootNode.childNodes*.childNodes[j].firstChild;
    o[node] = nodeValue; 
    trace(node + ": " + o[node]);
  }
  
}

```

The part I don’t understand is

```auto

o[node]

```

How does this look in the object o.  
I understand objects with the . syntax but as an array  
I guess I would like a visual of how o[node] looks in an object.  
example of o.label

```auto

o={label:"label_1",label:"label_2",label:"label_3"}

```
