私は次のようなXMLを持っています
var test:XML = new XML( <record id="5" name="AccountTransactions"
<field id="34" type="Nuber"/>
</record>);
id以外のすべての属性を削除し、XMLのすべてのノードに入力したいと思います。このコードでは、これを行うことはできません。ループ以外のより良い解決策を提案できますか?
var atts:XMLListCollection = new XMLListCollection(test.descendants().attributes().((localName() != "id") && (localName() != "type")));
atts.removeAll(); trace(test)
それでもすべての属性が表示されます:/