Posted on Mary 13, 2010 at 07.56 PM - Kuala Lumpur, Malaysia
Following is the procedure to implement Java XSLT in PI
Example XSLT:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:ns="http://bit460.com/xi/mapping##"
xmlns:ns0="urn:education.com:BIT460:mapping">
<xsl:template match="ns:MtCustomerName">
<xsl:call-template name="NameMerge"/>
</xsl:template>
<xsl:template name="NameMerge">
<ns0:MtName>
<xsl:value-of select="Name"/>
<xsl:text> </xsl:text>
<xsl:value-of select="Surname"/>
</ns0:MtName>
</xsl:template>
</xsl:stylesheet>
If we want to get the runtime constant, below is the example coding for getting it.
Example XSLT <xsl:param name="SenderService" /> <xsl:value-of select="$SenderService"/>
Example XSLT to display message or trace
<xsl:message terminate=[yes|no]> <!-- Output Message --> </xsl:message> ... <xsl:message terminate="no"> This is a warning! </xsl:message>
Life is beautiful! Let's make it meaningful and colorful!