[Home] [By Thread] [By Date] [Recent Entries]
> > I wouldn't rely on sibling relationships. > > Ok. Why would relying on such relationships be a "bad" thing though? > What are the benefits of introducing an <entry> tag in the <dict> > structure? It makes the processing code much more clear. Compare <xsl:value-of select="entry[key=$p]/value"/> To <xsl:value-of select="key[.=$p]/following-sibling::*[1]"/> It's also more extensible. If you use an XQuery implementation that doesn't support the sibling axes, then the version that relies on sibling relationships is going to be really hard work to process. (Some XQuery vendors have been very resistant to providing the sibling and ancestor axes.) Michael Kay http://www.saxonica.com/
|

Cart



