You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by David Delgranche <dd...@silicom.fr> on 2000/12/20 11:01:23 UTC
Problem with Redirect Extension
Hi,
I'm using redirect extension of xalan on a xml schema. I would like
dependng of the tag I meet outputting on a specific file.
I use the redirect fonction and I have the following error:
XSL Error: Redirect extension: Could not get filename - file or select
attribute must return vald string., style tree node:
org.apache.xalan.xslt.ElemExtensionCall@40857281, source tree node:
xsd:element
Call to extension function failed: method call/new failed:
java.lang.reflect.InvocationTargetException target exception:
org.apache.xalan.xslt.XSLProcessorException:
XSL Error: Redirect extension: Could not get filename - file or select
attribute must return vald string., style tree node:
org.apache.xalan.xslt.ElemExtensionCall@40857281, source tree node:
xsd:element
Call to extension function failed: method call/new failed:
java.lang.reflect.InvocationTargetException target exception:
org.apache.xalan.xslt.XSLProcessorException:
XSL Error: Redirect extension: Could not get filename - file or select
attribute must return vald string., style tree node:
org.apache.xalan.xslt.ElemExtensionCall@40857281, source tree node:
xsd:element
Call to extension function failed: method call/new failed:
java.lang.reflect.InvocationTargetException target exception:
org.apache.xalan.xslt.XSLProcessorException:
XSL Error: Redirect extension: Could not get filename - file or select
attribute must return vald string., style tree node:
org.apache.xalan.xslt.ElemExtensionCall@40857281, source tree node:
xsd:element
Call to extension function failed: method call/new failed:
java.lang.reflect.InvocationTargetException target exception:
org.apache.xalan.xslt.XSLProcessorException:
XSL Error: Redirect extension: Could not get filename - file or select
attribute must return vald string., style tree node:
org.apache.xalan.xslt.ElemExtensionCall@40857281, source tree node:
xsd:element
Call to extension function failed: method call/new failed:
java.lang.reflect.InvocationTargetException target exception:
org.apache.xalan.xslt.XSLProcessorException:
My XSLT code is the following:
<redirect:write select="permanenteTable.xml">
<xsl:element name="table">
<xsl:attribute name="name">lib_<xsl:value-of select="@name"/>
</xsl:attribute>
<xsl:element name="column">
<xsl:attribute name="name">id</xsl:attribute>
<xsl:attribute name="type">integer</xsl:attribute>
<xsl:element name="primaryKey"/>
</xsl:element>
<xsl:for-each
select="xsd:complexType/xsd:element/xsd:complexType/xsd:attribute[@type!='xsd:ID']">
<xsl:call-template name="attribut"/>
</xsl:for-each>
<xsl:for-each
select="xsd:complexType/xsd:element/xsd:complexType/xsd:element[@maxOccurs='1'and
@type!='xsd:ID']">
<xsl:call-template name="attribut"/>
</xsl:for-each>
</xsl:element>
</redirect:write>
Can anyone help me? I'm really in a urge....
--
David DELGRANCHE - ddelgranche@silicom.fr
Silicom RĂ©gion Ouest
80 avenue des Buttes de Coesmes 35700 RENNES
Tel: 02 99 84 17 17
Fax: 02 99
Re: Problem with Redirect Extension
Posted by Gary L Peskin <ga...@firstech.com>.
David Delgranche wrote:
> I'm using redirect extension of xalan on a xml schema. I would like
> dependng of the tag I meet outputting on a specific file.
> ...
> My XSLT code is the following:
> ...
> <redirect:write select="permanenteTable.xml">
> ...
> Can anyone help me? I'm really in a urge....
The select attribute takes an XPath expression, not a String. Try:
<redirect:write select="'permanenteTable.xml'">
HTH,
Gary