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

Re: Question of performance

Subject: Re: Question of performance
From: "Ragulf Pickaxe" <jawxml@xxxxxxxxxxx>
Date: Wed, 31 Oct 2001 09:37:10 +0000
aposthrophe
Hmmmm,

They are of some 15 lines about which 5 of them are context dependent. My thought is that the rest of the 10 lines may be put into a separate variable that can be declared globaly (that is, if performance will be better).
The static lines are simple html/javascript code, since the xsl is used for generating webpages from xml documents.
This is the amount of complexity in the variables.


---
On the same subject, I have a function (template) that is called recursively which also has a variable, ...Aposthrophe>'</xsl:variable> that is used in the template to escape aposthrophes in a string:
<xsl:when $Char=$Aptosthrophe">
<xsl:value-of select="concat('\',$Aposthrophe)"/>
</xsl:when>


As the variable is declared in the top of the template, is this declaration processed each time (I think that it must) and would the code be faster, though less maintainable, if I declare this (static) variable globally?

---
Is there a rule of thomb about when it is best to declare variables in xsl in their scope for better perofrmance compared to how readable the code in question is to be.


Ragulf


From: ronald heller <ronald@xxxxxxxxxxx>
Reply-To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  Question of performance
Date: Wed, 31 Oct 2001 09:53:27 +0100

I would say it also depends on the complexity of your variable and what
your preocessor needs to do to get the value, can you post an example?



_________________________________________________________________ Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


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.