RE: [xsl] Howto 'setParameters' with 'XMLFilters' ?

Subject: RE: [xsl] Howto 'setParameters' with 'XMLFilters' ?
From: "Michael Kay" <michael.h.kay@xxxxxxxxxxxx>
Date: Thu, 8 Aug 2002 10:53:08 +0100
> Joking apart ;-) 
> 
> Am I the only one who wants to use XMLFilters
> and setting stylesheets parameters ? 
> 
> I think, why not extending the XMLFilters by a method 
> 'setParameter'? Ok I can image that (due the fact that 
> XMLFilter is an extenion to XMLReader) there might be some 
> problems - but wouldn't it make sense ?
> 

If I remember correctly, this was deliberately excluded from JAXP on the
grounds that the purpose of the SAXTransformerFactory idea is to create
an XMLFilter that looks exactly like any other XMLFilter and has no
special characteristics. But I'm not convinced by the argument - it
would have been quite possible to define a subclass of XMLFilter that
includes a setParameter (or getTransformer) method. I'm intending to
provide this in a future Saxon release.

Meanwhile, if you transformation uses parameters, you have to rely on
the regular transform() interface, using a SAXSource and a SAXResult -
which isn't so convenient for pipelining.

Michael Kay
Software AG
home: Michael.H.Kay@xxxxxxxxxxxx
work: Michael.Kay@xxxxxxxxxxxxxx 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread