У меня есть входной XML, как это
<parent>
<child type="reference">
<grandChild name="aaa" action="None">
<Attribute name="xxx">1</Attribute>
<grandChild name="bbb" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
<grandChild name="ccc" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</grandChild>
<grandChild name="ddd" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</child>
</parent>
и я хочу разделить его на несколько xmls только с тегами parent-> child-> grandChild. В целом приведенный выше пример должен быть преобразован в 4 xmls (из-за 4 grandChild). Как это -
<parent>
<child type="reference">
<grandChild name="aaa" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</child>
</parent>
<parent>
<child type="reference">
<grandChild name="bbb" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</child>
</parent>
<parent>
<child type="reference">
<grandChild name="ccc" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</child>
</parent>
<parent>
<child type="reference">
<grandChild name="ddd" action="None">
<Attribute name="xxx">1</Attribute>
</grandChild>
</child>
</parent>
Может кто-нибудь, пожалуйста, подскажите мне об этом? Я искал некоторые альтернативы разделителя коллекций, которые были на Муле 3 или любым другим возможным способом.