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

RE: Calling subdocuments with processing directives

Subject: RE: Calling subdocuments with processing directives
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Fri, 26 Oct 2007 18:41:15 +0100
RE:  Calling subdocuments with processing directives
> The "default" you refer to is on retrieval. It is not clear 
> to me why that context is relevant in the case of keys. Why 
> do you have to specify the source of the value? That seems 
> very odd to me. The name of the key includes the source path?

The key definition includes a pattern - a condition that nodes must satisfy
in order to be eligible. You seem to be suggesting that you would like the
search in some sense to be global - to search all known documents. There
seems to be something of a closed world assumption there. All documents
previously loaded using the document() function? But what does "previously"
mean in XSLT - there's no defined order of execution. 

Consider

<xsl:variable name="doc1" select="document('foo.xml')"/>
<xsl:variable name="bbb" select="key('k', 93.7)"/>

Should $doc1 be searched? Why? It typically isn't loaded until it's needed,
and if no-one ever refers to $doc1 then it never will be loaded.

Michael Kay
http://www.saxonica.com/

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.