XSLT 変換に取り組んでいます。タグと呼ばれるタグがあるソースファイルがあります。
ソース xml がこのようなものであると考えてください。
<ABC>
<Name>Some Name </Name>
<ID>Some ID</ID>
<Address>Some Address</Address>
<Place>Some Place</Place>
<ID>Some ID</ID>
<Name>Some Name </Name>
<Name>Some Name </Name>
</ABC>
ルール:
ABC is parent Tag which has 4 child tags. Name, ID, Address, Place.
These child tags can occur many times and in any ordrer.
Upon reading the tag , I want to change the name of the tag, and do some processing on the value present in the tag.
The input XML may have child tags in any order, and many times.
I want to write a common XSLT which will read the child tags in the order in which they occur, and display them as given under.
このような出力を表示したい。
<Frame:Name>
<text>Some Name</text>
</Frame:Name>
<Frame:ID>
<text>Some ID</text>
</Frame:ID>
<Frame:ADdrress>
<text>Some Address</text>
</Frame:Address>
<Frame:Place>
<text>Some Place</text>
</Frame:Place>
<Frame:ID>
<text>Some ID</text>
</Frame:ID>
<Frame:Name>
<text>Some Name</text>
</Frame:Name>
<Frame:Name>
<text>Some Name</text>
</Frame:Name>
どうやってそれができるのか、私は完全に感銘を受けました。
ソース XML で子要素の出現順序が変更された場合、出力 XML にも反映される必要があります。
誰かがレビューを共有できますか。
ありがとうございました。