Re: [xsl] XSLT and Golden Hammers ...

Subject: Re: [xsl] XSLT and Golden Hammers ...
From: Gunther Schadow <gunther@xxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 11 Dec 2002 18:34:04 -0500
J.Pietschmann wrote:

>> What's wrong with doing it in XSLT?
> See Mike Kay's post: if your DB access causes side effects, you
> are in trouble.

Well, Michael didn't say "causes trouble." In fact, there are many ways
of getting around the problem. Some more elegant than others. That
Michael must be a pragmatist shows in his xsl:variable/@saxon:assignable
extension :-).

What I was looking for wasn't so much a lament over how hard it is
and that I want imperative program logic in XSLT, I was looking for
interesting ways of getting side effects married to XSLT. Philip
Wadler uses the metaphor of the mind-body problem. I love XSLT
because it enables me to do so much more in so little amount of
programming that I like to push the envelope a little.

Just because people like a language and want to use it a lot,
doesn't mean it's a Golden Hammer. Java isn't, or is it? I find
the notion of transforming information a very powerful approach
to many problems that don't have anything to do with users
looking documents.

In order for making this Golden Hammer argument, you'd have to
show that there is something intrinsicly constraining or
inadequate about using the XSLT approach for whatever I am
doing. Certainly a functional language isn't inadequate for
many things, and *managing* side-effects (not willy-nilly
sneaking in unsafe side-effects) is an interesting challenge.

> XSLT has its
> strenghts but also weaknesses. I wouldn't write a C compiler
> or orbital calculations with XSLT.

What do you suppose are the "weaknesses" of XSLT that you mention
that would make XSLT inadequate for, say, a database querying
web service application? Writing a C-compiler in XSLT? Not too
bad of a thought either, if C was expressed as XSLT. A compiler
is a very nice example for an application that essentially is
a transform. Orbital calculations? Well, what you might do with
an SVG presentation layer could come pretty close to that.


Gunther Schadow, M.D., Ph.D.                    gschadow@xxxxxxxxxxxxxxx
Medical Information Scientist      Regenstrief Institute for Health Care
Adjunct Assistant Professor        Indiana University School of Medicine

XSL-List info and archive:

Current Thread