[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Sequential numbers in pure xslt, breaking the no-

Subject: Re: Sequential numbers in pure xslt, breaking the no-side-effect rule
From: Nic James Ferrier <nferrier@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 16 Mar 2007 14:47:56 +0000
Re:  Sequential numbers in pure xslt
Abel Braaksma <abel.online@xxxxxxxxx> writes:

> AFAIK the answer to this is a simple, short "no, cannot be done". But I 
> wanted to check it with the specialists to be sure ;)
>
> The request is simple: create a function that returns '1' on first call, 
> and returns one higher each next call, without overlaps or jumps, 
> without any input. Let's call it my:seq-number:
>
> <xsl:function name="my:seq-number" as="xs:integer">
>     <!-- some implementation -->
> </xsl:function>
>
> then the following line would return '1 2 3':
> <xsl:value-of select="my:seq-number(), my:seq-number(),
> my:seq-number()" />

Are  monads possible in XSLT?


-- 
Nic Ferrier
----------------------------------------------------------
Need a linux/java/python/web hacker?  I'm in need of work!
----------------------------------------------------------
http://www.tapsellferrier.co.uk   

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.