私はエントリのセットを持つXMLファイルを持っている:集約XMLブロック
<PurchaseOrder PurchaseOrderNumber="99503" OrderDate="1999-10-20">
<Address Type="Shipping">
<Name>Ellen Adams</Name>
<Street>123 Maple Street</Street>
<City>Mill Valley</City>
<State>CA</State>
<Zip>10999</Zip>
<Country>USA</Country>
</Address>
<Item PartNumber="872-AA">
<ProductName>Lawnmower</ProductName>
<Quantity>1</Quantity>
<USPrice>148.95</USPrice>
<Comment>Confirm this is electric</Comment>
</Item>
</PurchaseOrder>
<PurchaseOrder PurchaseOrderNumber="99505" OrderDate="1999-10-22">
<Address Type="Shipping">
<Name>Cristian Osorio</Name>
<Street>456 Main Street</Street>
<City>Buffalo</City>
<State>NY</State>
<Zip>98112</Zip>
<Country>UK</Country>
</Address>
<Item PartNumber="456-NM">
<ProductName>Power Supply</ProductName>
<Quantity>1</Quantity>
<USPrice>45.99</USPrice>
</Item>
</PurchaseOrder>
を私の目的は、国ごとに異なるファイルのグループにすべての注文です。たとえば、us.xmlファイル内のすべての米国の注文。 私は(それが唯一のエントリの最後のグループがファイルorders.xmlに書き込まれますように)各グループのファイル名を指定する方法がわからないが、私は以下の集約戦略
<aggregate strategyRef="myAggregationStrategy"
completionSize="10" completionTimeout="500">
<correlationExpression>
<xpath>/PurchaseOrder/Address/Country/text()</xpath>
</correlationExpression>
<to uri="file:/home/data/other?fileName=orders.xml" />
</aggregate>
のために配置されています。 助けてください? ありがとう!
非常に明確で有益! – Carla