Code: Select all
else if$node.name == 'array'
$array.size=xml get attribute: data=$a.xmlData, attribute='size'
$children.count=xml get number of children: $a.xmlData
if$array.size
$return.data=array alloc: size=$array.size
$i=0
while$i < $children.count
$child=xml get child: $a.xmlData, id=$i
$child.name=xml get attribute: data=$child, attribute='name'
@ $ret=[THIS] -> call script lib.xml.get.data : XML Data=$child
ifis datatype[ $ret ] == DATATYPE_ARRAY
$child.name=$ret[0]
$ret=$ret[1]
end
do ifis datatype[ $child.name ] == DATATYPE_STRING
$child.name=string $child.name to integer
skip if$child.name
$child.name=0
$return.data[$child.name] = $ret
inc $i=
end
else
$return.data=array alloc: size=0
end
$return.data=create new array, arguments=$name, $return.data, null, null, null
lib.xml.get.data.rar