123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778 |
- <?xml version="1.0" encoding="UTF-8" ?>
- <!--
- +=========================================================================+
- | Licensed Materials - Property of IBM |
- | BI and PM: prmt |
- | (C) Copyright IBM Corp. 2002, 2016 |
- | |
- | US Government Users Restricted Rights - Use, duplication or |
- | disclosure restricted by GSA ADP Schedule Contract with IBM Corp. |
- | |
- +=========================================================================+
- -->
- <stylesheet version="1.0" xmlns="http://www.w3.org/1999/XSL/Transform">
- <output method="text" encoding="UTF-8"/>
- <template match="/">
- <text>/*
</text>
- <text> *+=========================================================================+
</text>
- <text> *| IBM Confidential |
</text>
- <text> *| Licensed Materials - Property of IBM |
</text>
- <text> *| BI and PM: prmt |
</text>
- <text> *| (C) Copyright IBM Corp. 2002, 2016 |
</text>
- <text> *| |
</text>
- <text> *| US Government Users Restricted Rights - Use, duplication or |
</text>
- <text> *| disclosure restricted by GSA ADP Schedule Contract with IBM Corp. |
</text>
- <text> *| |
</text>
- <text> *+=========================================================================+
</text>
- <text>*/
</text>
-
- <for-each select="stringTable/component">
- <variable name="comp_name" select="@name" />
- <for-each select="section">
- <variable name="sect_name" select="@name" />
- <if test="$sect_name != 'STC' and $sect_name != 'DFP' and $sect_name != 'CON'">
- <for-each select="string">
- <text>var </text> <value-of select="$comp_name" />_<value-of select="$sect_name" />_<value-of select="@id" />
- <text> = "</text>
- <call-template name="replaceChar">
- <with-param name="text">
- <call-template name="replaceChar">
- <with-param name="text" select="." />
- <with-param name="toReplace">\</with-param>
- <with-param name="replaceWith">\\</with-param>
- </call-template>
- </with-param>
- <with-param name="toReplace">"</with-param>
- <with-param name="replaceWith">\"</with-param>
- </call-template>
- <text>";
</text>
- </for-each>
- </if>
- </for-each>
- </for-each>
- </template>
-
- <template name="replaceChar">
- <param name="text" />
- <param name="toReplace" />
- <param name="replaceWith" />
- <choose>
- <when test="contains($text, $toReplace)">
- <variable name="beforeChar" select="substring-before($text,$toReplace)" />
- <variable name="afterChar">
- <call-template name="replaceChar">
- <with-param name="text" select="substring-after($text,$toReplace)" />
- <with-param name="toReplace" select="$toReplace" />
- <with-param name="replaceWith" select="$replaceWith" />
- </call-template>
- </variable>
- <value-of select="concat($beforeChar, $replaceWith, $afterChar)" />
- </when>
- <otherwise>
- <value-of select="$text" />
- </otherwise>
- </choose>
- </template>
- </stylesheet>
-
|