Re: Designs for XSLT functions (Was: Re: [xsl] RE: syntax sugar for call-template)

Subject: Re: Designs for XSLT functions (Was: Re: [xsl] RE: syntax sugar for call-template)
From: Jeni Tennison <mail@xxxxxxxxxxxxxxxx>
Date: Tue, 20 Feb 2001 09:24:42 +0000

I think that the discussions that we're having are very useful in
throwing up the issues involved in authoring extension functions in

However, I'm concerned that we're losing focus a little and would like
to explicitly state a few assumptions that I think we should be
working under.  As always, if you disagree with these assumptions or
if you would like others to be added, then do pipe up.

1. There are three sets of extensions that we could be talking about:

(a) extensions to XSLT 1.0
(b) extensions to XSLT 1.1
(c) extensions to XSLT 2.0

I think that we should be addressing (a) and (b) and not even thinking
about XSLT 2.0 as yet.  In fact, I think we should address (a) now,
(b) immediately after we've done that and (c) at some far distant time
when we've all recovered a bit and it's a little clearer what XSLT 2.0
and XPath 2.0 are going to look like.

So, let's limit ourselves (for now) to extensions to XSLT 1.0.  This
is a bit of a change 'cos I was talking about xsl:script before, but I
think it will simplify some of the discussion.

If we are limited to XSLT 1.0 then there are certain things that we
cannot do. In particular, we, as extension designers, can't make major
changes to XPath such as introducing conditional (test ? true : false)
paths or a new way of passing arguments to functions. We are limited
to creating extension functions and extension elements.  It's not
because these ideas aren't great - they are! - but because XSLT limits
what we can change.

2. I'm persuaded by Steve's observation that static invocation is very
different from dynamic invocation and that dynamic invocation is
something that could be applied to functions (and indeed XPaths)
across the board.  I think that we should focus the discussion now on
static invocation, and address dynamic invocation once we've got that
out of the way.

So, the order I'm suggesting to focus discussions is:

1. how to define extension functions in XSLT 1.0
2. how to statically invoke extension functions in XSLT 1.0
3. how to dynamically invoke extension functions (+ other things?) in
   XSLT 1.0
4. how to define extension functions in XSLT 1.1

I'll summarise the proposals and design questions that have come out
so far for 1. in one of my following emails.



Jeni Tennison

 XSL-List info and archive:

Current Thread