Return-Path: Delivered-To: apmail-xml-xalan-j-users-archive@xml.apache.org Received: (qmail 80546 invoked by uid 500); 2 Oct 2002 14:07:22 -0000 Mailing-List: contact xalan-j-users-help@xml.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Delivered-To: mailing list xalan-j-users@xml.apache.org Received: (qmail 80397 invoked from network); 2 Oct 2002 14:07:17 -0000 Received: from unknown (HELO s0001670.servers.kbc.be) (193.244.32.7) by daedalus.apache.org with SMTP; 2 Oct 2002 14:07:17 -0000 Received: from s816721.ccm.kb.be (unverified) by s0001670.servers.kbc.be (Content Technologies SMTPRS 4.2.5) with ESMTP id for ; Wed, 2 Oct 2002 16:15:28 +0200 Subject: set stylesheet parameters when using transformation chaining! To: xalan-j-users@xml.apache.org X-Mailer: Lotus Notes Release 5.0.4 June 8, 2000 Message-Id: From: robbie.ceulemans@kbc.be Date: Wed, 2 Oct 2002 16:07:02 +0200 X-MIMETrack: Serialize by Router on AHUBBE01/SERVERS(Release 5.0.8 |June 18, 2001) at 02/10/2002 16:07:04 MIME-Version: 1.0 Content-type: text/plain; charset="us-ascii" X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N Status: O X-Status: X-Keywords: I am using the SAX Transformation chaining capabilities of Xalan. However, setting a parameter to the transformer doesn't seem to work. code: SAXTransformerFactory stf = (SAXTransformerFactory) TransformerFactory.newInstance(); XMLFilter filter = stf.newXMLFilter(new StreamSource("test.xslt")); StreamResult sr = new StreamResult(System.out); Transformer transformer = stf.newTransformer(); SAXSource transformSource = new SAXSource(filter, new InputSource ("test.xml")); transformer.setParameter("testParam", "value"); transformer.transform(transformSource, sr); The parameter is not passed to the stylesheet. It works when I just transform the xml from the commandline (org.apache.xalan.xslt.Process). When I had a look at the code I saw that for transformation chaining, the TransformerIdentityImpl is used instead of the TransformerImpl. The implementation of the setParameter()-method is quiet different. The method in the TransformerIdentityImpl only seems to put the parameter in a Hashtable, and that's it. I don't see any place in the code where this Hashtable is used afterwards. Is this a bug or am I not supposed to use the setParameter()-method when doing transformation chaining? (or am I doing something wrong) Thanks alot for any help, Robbie ________________________________________________ DISCLAIMER This e-mail and any attached files are confidential and may be legally privileged. If you are not the addressee, any disclosure, reproduction, copying, distribution, or other dissemination or use of this communication is strictly prohibited. If you have received this transmission in error please notify KBC immediately and then delete this e-mail. KBC does not accept liability for the correct and complete transmission of the information, nor for any delay or interruption of the transmission, nor for damages arising from the use of or reliance on the information. All e-mail messages addressed to, received or sent by KBC or KBC employees are deemed to be professional in nature. Accordingly, the sender or recipient of these messages agrees that they may be read by other KBC employees than the official recipient or sender in order to ensure the continuity of work-related activities and allow supervision thereof.