[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Act as xsl:next-match in XSLT 1 with xsl:apply-im
> The reason is obvious: the XSLT 1.0 spec mandates that when two imports > are of equal import precedence (i.e., in the same file) then template > matches that appear lowest in the importing file take precedence and the > rest is discarded. Because of "being discarded", I believe the > <xsl:apply-imports /> does not work recursively. I don't think that the spec describes these templates as being discarded, and in fact two imports are never in equal precedence. However (unfortunately) apply-imports is not defined to mean "next match in import precedence order" it is only defined to consider stylesheets that are imported into _this_ stylesheet module, so in a situation where one stylesheet imports all the rest, any apply-imports in the imported files will be a no-op as they don't themeselves have any imports. As you said You need a thin deep tree, not a short fat one if you want to use xsl:apply-imports. The semantics of xslt 2's next match are a lot easier to understand, more or less: "choose the template you would have chosen if this one had not been here". David
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|