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

Re: questions about XSLT philosophy: how much is too m

Subject: Re: questions about XSLT philosophy: how much is too much?
From: Dimitre Novatchev <dnovatchev@xxxxxxxxx>
Date: Wed, 19 Mar 2003 08:14:52 -0800 (PST)
xslt exponentiation
---- "Robert P. J. Day" <rpjday@xxxxxxxxxxxxxx> wrote:

>   so what's next?  adding even more math functions?  max()?
> min()?  i notice in kay's book the list of exclusively 
> saxon-related extensions, including more math functions,
> set functions and the like.

max and min are only of average difficulty. Some more challenging
examples of what can be accomplished with XSLT can be seen at:

http://fxsl.sourceforge.net/


Just to name a few:

 - higher order functions
 - functional composition
 - partial application, currying
 - dynamic creation of functions

 - generic iteration
 - generic recursion over lists
 - generic recursion over trees
 - mapping, zipping, splitting, filtering of lists

 - generic binary search in Ordered
 - generic sort in Ordered

 - generic recursion over the characters of a string
 - mapping, zipping, splitting, filtering of lists of characters 
  (strings).
 - string tokenisation, trimming and reversal
 - text justification
 - spelling checking and generation of correct close words.
 

 - numerical differentiation
 - numerical integration
 - limits of sequences
 - trigonometric functions, hyperbolic trigonometric functions
 - logarithmic and exponentiation functions
 - inverse trigonometric functions.
 - roots of a continuous function with one real variable.

 - random numbers, random numbers with specified distribution.
 - randomisation of lists/node-sets.

 - implementation of lazy evaluation.
 - implementation of a mechanism (closely matching the "Monad 
   someType" class) for using reliably functions with side effects.

(the last two are not yet published).


> it seems
> that a lot of what XSLT is being used for is starting to
> push the bounds of what i initially considered stylesheet
> "transformation", and that XSLT is getting strangely close
> to being a fully-featured programming language.  

Nothing strange -- XSLT is Turing-complete and this means that it is in
the group of the most powerful languages.

What some people argue is whether it is easy to accomplish the above
tasks in XSLT.

The conclusion from my own practice is that this is not so difficult
when the XSLT programmer is supported by a library of higher order
functions, which implement some most general functional programming
design patterns.


> 
>   so i'm curious.  what is the eventual goal?  

 1. To support the development of portable XSLT applications.
 2. To simplify XSLT programming and make it a more efficient process 
    by increasing the possibilities of components reuse.
 3. Purely aesthetical, to use a functional programming language 
   (contrasted to an imperative one) has an aesthetic and intellectual 
    value in itself.
 4. To contribute to the understanding of XSLT, (hopefully) to help in 
    the further development of XSLT.






=====
Cheers,

Dimitre Novatchev.
http://fxsl.sourceforge.net/ -- the home of FXSL

__________________________________________________
Do you Yahoo!?
Yahoo! Platinum - Watch CBS' NCAA March Madness, live on your desktop!
http://platinum.yahoo.com

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


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.