我有一个arrayList:
public var exampleData:IList = new ArrayList([
{title: 'data1', data:[
{label:'IT', value: 50},
{label:'Business', value: 46},
{label:'Doctor', value: 64},
{label:'Teacher', value: 85},
{label:'Engineer', value: 98}
]} ,
{title: 'data2', data:[
{label:'IT', value: 63},
{label:'Businss', value: 46},
{label:'Doctor', value: 38},
{label:'Tea', value: 51},
{label:'Enee', value: 24}
]} ,
{title: 'data3', data:[
{label:'IT', value: 37},
{label:'Business', value: 58},
{label:'Doctor', value: 48},
{label:'Teacher', value: 14},
{label:'Engineer', value: 28}
]}, ]);
我想在arrayList中比较每个数组的标签字段。默认值,与第一个数组(标题:'data1')进行比较。类似于以下结果:
public var resultData:IList = new ArrayList([
{title: 'data1', data:[
{label:'IT', value: 50},
{label:'Business', value: 46},
{label:'Doctor', value: 64},
{label:'Teacher', value: 85},
{label:'Engineer', value: 98}
]} ,
{title: 'data3', data:[
{label:'IT', value: 37},
{label:'Business', value: 58},
{label:'Doctor', value: 48},
{label:'Teacher', value: 14},
{label:'Engineer', value: 28}
]}, ]);