[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

xsL:with-param, xsl:-param emptiness, Xalan and xsltpr

Subject: xsL:with-param, xsl:-param emptiness, Xalan and xsltproc
From: Eric White <eric.white@xxxxxxxxxxx>
Date: Thu, 23 Mar 2006 09:15:12 -0600
xsl with param
I've tried both xalan (2.7.0) and xsltproc (compiled against libxml 20623, libxslt 10115 and libexslt 812) and can't get xsl:with-param calls to show up in my xsl:param arguments to templates. The included xsl shows the various forms/syntaxes I've tried, to no avail. Since both Xalan and xsltproc exhibit the same behavior, the problem must lie in my construct or syntax. Any help is greatly appreciated.

<?xml version="1.0" encoding="ISO-8859-1"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:saxon="http://icl.com/saxon"
extension-element-prefixes="saxon" >
<xsl:output method="xml"/>

<xsl:template match="/">
<xsl:apply-templates select="*"/>
<xsl:for-each select="physInterfaceTableRow">
<xsl:choose>
<xsl:when test="physInterfaceOsName='eth0'">
<xsl:call-template name="physInterfaceSupportedAutonegotiation">
<xsl:with-param name="SupportedNegotiate" select="'true'"/>
</xsl:call-template>
<xsl:call-template name="physInterfaceAdvertisedAutonegotiation">
<xsl:with-param name="AdvertisedNegotiate">'true'</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="physInterfaceDuplex">
<xsl:with-param name="DuplexCapability">full</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="physInterfaceBandwidthLimit">
<xsl:with-param name="BandwidthLimit">4391</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="physInterfaceSpeed">
<xsl:with-param name="BandwidthLimit">4391</xsl:with-param>
</xsl:call-template>
</xsl:when>
<xsl:when test="physInterfaceOsName='eth1'">
<xsl:apply-templates>
<xsl:with-param name="SupportedNegotiate" select="true"/>
<xsl:with-param name="AdvertisedNegotiate">true</xsl:with-param>
<xsl:with-param name="DuplexCapability">full</xsl:with-param>
<xsl:with-param name="BandwidthLimit">4391</xsl:with-param>
</xsl:apply-templates>
</xsl:when>
<xsl:when test="physInterfaceOsName='eth2'">
<xsl:apply-templates>
<xsl:with-param name="SupportedNegotiate">true</xsl:with-param>
<xsl:with-param name="AdvertisedNegotiate">true</xsl:with-param>
<xsl:with-param name="DuplexCapability">full</xsl:with-param>
<xsl:with-param name="BandwidthLimit">4391</xsl:with-param>
</xsl:apply-templates>
</xsl:when>
</xsl:choose>
</xsl:for-each>
</xsl:template>



<xsl:template match="*"> <xsl:copy> <xsl:copy-of select="@*"/> <xsl:apply-templates/> </xsl:copy> </xsl:template>

<xsl:template match="physInterfaceTableRow">
<xsl:element name="physInterfaceTableRow">
<xsl:apply-templates/>
</xsl:element>
</xsl:template>

<xsl:template match="physInterfaceSupportedAutonegotiation">
<xsl:param name="SupportedNegotiate"/>
<xsl:element name="physInterfaceSupportedAutonegotiation"><xsl:value-of select='$SupportedNegotiate'/></xsl:element>
</xsl:template>


<xsl:template match="physInterfaceAdvertisedAutonegotiation">
<xsl:param name="AdvertisedNegotiate"/>
<xsl:element name="physInterfaceAdvertisedAutonegotiation"><xsl:value-of select="$AdvertisedNegotiate"/></xsl:element>
</xsl:template>


<xsl:template match="physInterfaceDuplex">
<xsl:param name="DuplexCapability"/>
<xsl:element name="physInterfaceDuplex"><xsl:value-of select="$DuplexCapability"/></xsl:element>
</xsl:template>


<xsl:template match="physInterfaceBandwidthLimit">
<xsl:param name="BandwidthLimit"/>
<xsl:element name="physInterfaceBandwidthLimit"><xsl:value-of select="$BandwidthLimit"/></xsl:element>
</xsl:template>


<xsl:template match="physInterfaceSpeed">
<xsl:param name="BandwidthLimit"/>
<xsl:element name="physInterfaceSpeed"><xsl:value-of select="$BandwidthLimit"/></xsl:element>
</xsl:template>


</xsl:stylesheet>

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.