RE: topological sort2003-10-09 00:41:04The algorithm is O(n^2) for a simple XSLT processor, but it would be O(n) if the XSLT processor was smart enough to cache the values returned from the computeWeight(node) function. Does saxon do this? Maybe it would if I used keys. You can set saxon:memo-function="yes" on xsl:function to cause this behaviour. Michael Kay XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
|