Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

RE: Invoking Saxon from ANT: msg#00064

text.xml.saxon.help

Subject: RE: Invoking Saxon from ANT

Hi Brett

Thanks for confirming what I had discovered.

For reference, the 'not-easy' way I currently use is:

<java fork="true" jar="C:/Tools/Saxon/saxon7.jar">
<arg line="-o out.xml"/>
<arg line="in.xml"/>
<arg line="stylesheet.xsl"/>
</java>

rather than the hoped for 'easy' way

<!-- some magic Saxon configuration operation -->
<xslt style="stylesheet.xsl" in="in.xml" out="out.xml"/>

or slightly less easy way documented in the ANT pages:

<xslt style="stylesheet.xsl" in="in.xml" out="out.xml">
<factory name="net.sf.saxon.TransformerFactoryImpl"/>
</factory>
</xslt>

Unfortunately the above doesn't work - "factory" is not recognised.

I don't like changing near-system settings for potentially
local preferences, so I was hoping that there was some
standard ANT task available to do either a

System.setProperty("...")

or a saxon7.jar entry-point to do

System.setProperty("javax.xml.transform.TransformerFactory",
"net.sf.saxon.TransformerFactoryImpl")

before I wrote yet another one.

Regards

Ed Willink

------------------------------------------------------------------------
E.D.Willink, Email:
mailto:EdWillink-7KbaBNvhQFM@xxxxxxxxxxxxxxxx
Thales Research and Technology (UK) Ltd, Tel: +44 118 923 8278 (direct)
Worton Drive, or +44 118 986 8601 (ext 8278)
Worton Grange Business Park, Fax: +44 118 923 8399
Reading, RG2 0SB
ENGLAND http://www.computing.surrey.ac.uk/personal/pg/E.Willink
------------------------------------------------------------------------
> -----Original Message-----
> From: Brett Knights
> [mailto:brett-t37+GO5IUUYNrLj0LK0ixEEOCMrvLtNR@xxxxxxxxxxxxxxxx]
> Sent: 26 January 2004 15:51
> To: saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
> Subject: Re: [saxon] Invoking Saxon from ANT
>
>
> I think you mean
> <java classname="com.icl.saxon.StyleSheet"
> classpathref="saxon.classpath" fork="true">
>
> as WinStyleSheet is meant to be used with the MS JVM.
>
> I don't think that will work reliablye unless you also add:
> <jvmarg
> value="-Djavax.xml.transform.TransformerFactory=com.icl.saxon.Transfor
> merFactoryImpl"/>
>
> IMO though the easiest way is to create or update your
> $JAVA_HOME/jre/lib/jaxp.properties file to include:
> javax.xml.transform.TransformerFactory=com.icl.saxon.TransformerFactor
> yImpl
>
> that way the Saxon 6 xslt processor will always be the xslt processor
> that is used by ant's Style task.
> Unfortunately the Style task itself doesn't include a mechanism for
> selecting a specific processor.
>
> HTH
>
> ----- Original Message -----
> From: "David Benny" <david-benny-8d3DuiPIw7lBDgjK7y7TUQ@xxxxxxxxxxxxxxxx>
> To: <saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx>
> Sent: Monday, January 26, 2004 6:09 AM
> Subject: RE: [saxon] Invoking Saxon from ANT
>
>
> > Try something like
> >
> > <java classname="com.icl.saxon.WinStyleSheet"
> > classpathref="saxon.classpath" fork="true">
> > <arg value="-o"/>
> > <arg value="out.xml"/>
> > <arg value="in.xml"/>
> > <arg value="transform.xsl"/>
> > </java>
> > David
> >
> > -----Original Message-----
> > From: saxon-help-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
> > [mailto:saxon-help-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx]On
> > Behalf Of Willink,
> Ed
> > Sent: 26 January 2004 11:55
> > To: Saxon Help List (E-mail)
> > Subject: [saxon] Invoking Saxon from ANT
> >
> >
> > Hi All
> >
> > Is there an easy way to invoke Saxon as the XSLT support within ANT?
> >
> > It seems that the ANT Trax support needs just a little bit of help
> > from saxon7.jar.
> >
> > Regards
> >
> > Ed Willink
> >
> > --------------------------------------------------------------------
> ----
> > E.D.Willink, Email:
> mailto:EdWillink-7KbaBNvhQFM@xxxxxxxxxxxxxxxx
> > Thales Research and Technology (UK) Ltd, Tel: +44 118 923 8278
> (direct)
> > Worton Drive, or +44 118 986 8601 (ext
> 8278)
> > Worton Grange Business Park, Fax: +44 118 923 8399
> > Reading, RG2 0SB
> > ENGLAND
> http://www.computing.surrey.ac.uk/personal/pg/E.Willink
> > --------------------------------------------------------------------
> ----
> >
> >
> > -------------------------------------------------------
> > The SF.Net email is sponsored by EclipseCon 2004
> > Premiere Conference on Open Tools Development and Integration
> > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
> > http://www.eclipsecon.org/osdn
> > _______________________________________________
> > saxon-help mailing list
> > saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
> > https://lists.sourceforge.net/lists/listinfo/saxon-help
> > ---
> > Incoming mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.557 / Virus Database: 349 - Release Date: 30/12/2003
> >
> > ---
> > Outgoing mail is certified Virus Free.
> > Checked by AVG anti-virus system (http://www.grisoft.com).
> > Version: 6.0.557 / Virus Database: 349 - Release Date: 30/12/2003
> >
> >
> >
> > -------------------------------------------------------
> > The SF.Net email is sponsored by EclipseCon 2004
> > Premiere Conference on Open Tools Development and Integration
> > See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
> > http://www.eclipsecon.org/osdn
> > _______________________________________________
> > saxon-help mailing list
> > saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
> > https://lists.sourceforge.net/lists/listinfo/saxon-help
> >
>
>
>
>
> -------------------------------------------------------
> The SF.Net email is sponsored by EclipseCon 2004
> Premiere Conference on Open Tools Development and Integration
> See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
> http://www.eclipsecon.org/osdn
> _______________________________________________
> saxon-help mailing list
> saxon-help-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@xxxxxxxxxxxxxxxx
> https://lists.sourceforge.net/lists/listinfo/saxon-help
>


-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

Recently Viewed:
version-control...    qnx.openqnx.dev...    redhat.rhn.user...    ietf.openpgp/20...    mail.mutt.user/...    web.microformat...    java.sync4j.use...    education.ezpro...    user-groups.blu...    solaris.manager...    org.fitug.debat...    technology.erps...    politics.activi...    linux.redhat.fe...    bug-tracking.ma...    xfce.user/2004-...    hams/2004-11/ms...    kde.users.pim/2...    culture.cooking...    freebsd.devel.x...    gnu.m4.adhoc/20...    ngpt.user/2002-...    apple.fink.deve...   
Home | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe

Navigation