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

Re: passing a sequence as a parameter

Subject: Re: passing a sequence as a parameter
From: David Carlisle <davidc@xxxxxxxxx>
Date: Tue, 26 Feb 2008 16:57:27 GMT
Re:  passing a sequence as a parameter
> It seems, +param=filename will be Saxon specific. 

any command line syntax is system specific, even setting the source and
stylesheet names can not be done the same way for all systems.

> is it useful to desire a portable way to do this?
it's only a minor issue in any case, the difference beween

saxon9  it=main style.xsl +doc1=file1.xml 

<xsl:param name="doc1"/>
<xsl:value-of select="$doc1/a/b/c"/>

and

saxon9  it=main style.xsl doc1=file1.xml 

<xsl:param name="doc1"/>
<xsl:value-of select="doc($doc1)/a/b/c"/>


is largely cosmetic, the +param syntax is mainly useful if you have a
stylesheet written for an APi that can naturally accept document nodes
and you want to run it on the command line for some reason.
If you are writing it for the command line in the first place it's as
easy to pass in a stringand then call doc(). One other potential
advantage of +param is that if you pass in a string that's going to be
used as a parameter to doc() it needs to use URI syntax but the +param
symtax can use local system paths (which is useful if your command line
system will auto-complete pathnames for ypu as you type...)

David




________________________________________________________________________
The Numerical Algorithms Group Ltd is a company registered in England
and Wales with company number 1249803. The registered office is:
Wilkinson House, Jordan Hill Road, Oxford OX2 8DR, United Kingdom.

This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs. 
________________________________________________________________________

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.