[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

RE: [xsl] when to use xslt


Subject: RE: [xsl] when to use xslt
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Thu, 13 Jan 2005 23:33:57 -0000

A big question, but a good one. Trouble is, it needs a big answer, and I
don't have time to give one.

It depends a little bit on the task you are performing, and the alternative
approaches you are considering. Once you are over the learning curve, I
think that an XSLT solution to most XML transformation tasks (the tasks for
which the language was designed) will be shorter than solutions in other
languages: that generally means they will be faster to develop and easier to
maintain. A particular benefit is that if you use the rule-based programming
model for XSLT, the stylesheet will be very robust in the face of changes to
the schema of the source documents it is designed to process.

Don't believe arguments that XSLT is slow. For most straightforward
transformations, the execution time is dominated by the time to parse the
input and serialize the output, and that will be the same whatever language
you use. For more complex transformations, very large input documents, etc,
it's probably true that a good Java programmer could produce a faster
solution: but could they produce it faster?

One shouldn't discount arguments based on skills and experience. Most people
solving a programming problem will produce a better solution using poor
tools that they know well rather than good tools that are new to them. If
you're in a hurry, use the tools you know well. If you're taking a long-term
view, don't attach much weight to the experience of your first few days.

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



> -----Original Message-----
> From: Henning Waack [mailto:henning.waack@xxxxxx] 
> Sent: 13 January 2005 18:37
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: [xsl] when to use xslt
> 
> Dear all.
> 
> I'am looking for argument for and against xslt, that is when 
> is it useful to use (the functional language) xslt, when to 
> use some imperative programming language? Right now I am not 
> getting very far, except for some standard arguments like 
> xslt is slow, but xml itself etc. Can you point me to some 
> sophisticated points concerning this topic?
> 
> Thank you very much in advanced,
> 
> greetings,
> 
> Henning


Current Thread
Keywords