[xsl] Poluting XSLT??? (Was Re: Designs for XSLT functions )

Subject: [xsl] Poluting XSLT??? (Was Re: Designs for XSLT functions )
From: Dimitre Novatchev <dnovatchev@xxxxxxxxx>
Date: Thu, 22 Feb 2001 21:42:46 -0800 (PST)
> Because that creates a new node set stuffed full of *copies* of the
> nodes, not the original nodes.  You could do:
> 
>    <exsl:function>
>       <xsl:param name="nodes" />
>       <xsl:variable name="foo">
>          <xsl:for-each select="$nodes">
>             <xsl:sort />
>             <xsl:if test="5 &lt;= position()">
>                <node id="{generate-id()}" />
>             </xsl:if>
>          </xsl:for-each>
>       </xsl:variable>
>       <exsl:return select="$nodes[generate-id() = $foo/node/@id]" />
>    </exsl:function>
> 
> as a non-recursive and fairly hacky solution.


I'd rather see more professional discussion on the ways 
to extend XSLT with new and necessary functionality.

I have the feeling that the real implementors are watching with amusement
(if not bored already) this and other threads and just throwing in 
a few words from time to time.

While discussions like this can be useful it is just a first initial stage 
of a process in which the developers must step in later.

If left to people with little experience as XSLT implementors, 
we'll have pretty soon a variety of new xsl elements that are redundant 
and a language -- far from elegant.

In this particular case:

1. Sometimes ago I proposed a "xsl:reference-of" element
2. Other people think now of "xsl:append"

These two new elements will behave essetially as "xsl:copy-of", 
but with a small variation -- will output the same node -- not its copy.

Isn't it best to say that we only need the same "xsl:copy-of" element 
with a slightly changed syntax and behaviour? Like:

<xsl:copy-of select="expression" create-reference="yes|no">

This is just an example, which shows that in many cases it could be possible
not to add new elements to XSLT.

Maybe we need a separate mailing list, dedicated to XSLT language evolution
and development, where implementors will be the driving force and perform more
analytical work than sociological surveys.

I hate politics, especially when there's an attempt to mix it with technology.

Any attempt to extend a language by voting reminds me of "popular movements", 
"party meetings" and the well-known results of these in history.

Just as a summary -- it is not yet the time to propose decisions -- especially if
the key players have not actively stepped in.

Think before you act...

Dimitre Novatchev.





__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - Buy the things you want at great prices! http://auctions.yahoo.com/

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread