This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: xsl optimization



 From my experience when you uses
more detailed match - phrase in the xsl:template element
it can work faster

I was hawing (for multi language support) in my XML doc

<page>
         <labels>
                 <label id="1"> ............. </label>
                 <label id="2"> ............. </label>
         </labels>
</page>

at first I was selecting labels using this:

<xsl:value-of select="label[@id='2']"/>

and then changed it to:

<xsl:value-of select="/page/labels/label[@id='2']"/>

the result was quite good,
the page was generated 2 or 3 times faster

but every text on the page was transformed that way.


>Hi !
>
>Is there any possibility for optimizing an XSL ?
>
>I mean I work on a project right now and I count how much time it takes to
>parse an XML with an XSL through Java. Well in an old version it took way
>too much, while in a new version (with a new XSL) it works faster.
>
>So I want to know if the word "optimization" can be applied to XSL
>programming.
>If yes, anybody can tell me what are the principles for optimizing an XSL.
>
>Thank you in advance,
>Gabriel Erzse
>
>
>  XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list




-- 

Wyjedz z nami na Madagaskar!
Wez udzial w konkursie [ http://konkursy.onet.pl ]



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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]