ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Meals" <tme...@intraware.com>
Subject Re: XSLT processor & <param> tags
Date Tue, 31 Jul 2001 17:25:55 GMT
Stephane --

Sadly, the single quotes are required, otherwise Xalan will receive the user
name rather than a String representing the user name.  A quick test throws
org.apache.xalan.xslt.XSLProcessExceptions complaining about extra illegal
tokens with the value passed in.

I did have a chance to diff the 1.3 code line with one of the 1.4 nightly builds
and found a protected method that looks like it's setting the params for the
XSLT processor.  I'll look into applying the 1.4 XSLTProcessor class to the 1.3
code and see what happens.

Thanks,
Tim

Stephane Bailliez wrote:

> Does it work correctly if you remove the single quote for your params ?
>
> Xalan 2.x and Xalan 1.2.x do not work the same way for parameters, but maybe
> it is only in command line.
>
> --
>  St├ęphane Bailliez
>  Software Engineer, Paris - France
>  iMediation - http://www.imediation.com
>  Disclaimer: All the opinions expressed above are mine and not those from my
> company.
>
> > -----Original Message-----
> > From: Tim Meals [mailto:tmeals@intraware.com]
> > Sent: Monday, July 30, 2001 10:15 PM
> > To: ant-user@jakarta.apache.org
> > Subject: XSLT processor & <param> tags
> >
> >
> > Has anyone run into problems using the Xalan XSLT processor with the
> > <style> tag and losing parameters passed into the stylesheet?
> >  I have a
> > target set up like this:
> >
> > <target name="generate">
> >     <style basedir="." extension=".xml" destdir="${build.tmp}"
> > style="features/main.xsl">
> >         <include name="${build.subdir}/*.xml"/>
> >         <param name="build.user" expression="'${user.name}'"/>
> >         <param name="build.time" expression="'${build.time}'"/>
> >     </style>
> > </target>
> >
> > The above fragment works fine for the first file in the directory, but
> > doesn't set the parameters for any others it processes.  Is
> > this an Ant
> > problem, or a Xalan bug?  Has this already been addressed in
> > version 1.4
> > of Ant?  I'm using Xalan 2.0.D01.
> >
> > Thanks,
> > Tim
> >
> > --
> > Tim Meals
> > Web Applications Developer
> >
> > mailto:tmeals@intraware.com
> > fax:      925-253-4599               http://www.intraware.com
> > operator: 925-253-4500        Intraware ... Control Your Technology
> >
> >

--
Tim Meals
Web Applications Developer

mailto:tmeals@intraware.com
direct:   925-253-6515
fax:      925-253-4599               http://www.intraware.com
operator: 925-253-4500        Intraware ... Control Your Technology


Mime
View raw message