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

RE: how to output a processing instruction

Subject: RE: how to output a processing instruction
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Wed, 19 May 2010 16:25:41 +0100
RE:  how to output a processing instruction
The simplest way to be sure Saxon gets loaded is to replace this:

   TransformerFactory tfactory = TransformerFactory.newInstance();

with this:

  TransformerFactory tfactory = new net.sf.saxon.TransformerFactoryImpl();

It's more robust and a lot faster to boot. The only reason to use the
dynamic loading approach is when you don't want to commit your application
to a particular XSLT engine at application compile time.

Regards,

Michael Kay
http://www.saxonica.com/
http://twitter.com/michaelhkay 



> -----Original Message-----
> From: Bartolomeo Nicolotti [mailto:bnicolotti@xxxxxxxxx] 
> Sent: 19 May 2010 16:12
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Cc: Livio Costamagna; Gianluca Bruno
> Subject: Re:  how to output a processing instruction
> 
> Hello,
> 
> to use saxon in a java/jsp/tomcat web application up to now 
> we've done:
> 
>     	
> System.setProperty("javax.xml.transform.TransformerFactory", 
> "net.sf.saxon.TransformerFactoryImpl");
> 
>         // Create a transform factory instance.
>         TransformerFactory tfactory = 
> TransformerFactory.newInstance();
>         return tfactory;
> 
> 
> but now we've another web application on the same tomcat that 
> clashes with this, due to this problem
> 
> http://lists.cocoondev.org/pipermail/daisy/2006-September/005150.html
> 
> Does anybody know an equivalent of this statement
> 
>     	
> System.setProperty("javax.xml.transform.TransformerFactory", 
> "net.sf.saxon.TransformerFactoryImpl");
> 
> that applies only to a single web application?
> 
> Many thanks
> 
> Best ragards
> 
> 
> Bartolomeo Nicolotti

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.