xsl-list
[Top] [All Lists]

Re: [xsl] when to use 'as' attribute on a variable

2006-03-08 07:58:56

  Thanks for these precisions.  Which functions do you think
  about (that requires argument element to live in a tree)?



Well the most noticable one is the Xpath expression  /  which selects
the root of the current tree if you are in one but raises an error if
not, / is root() instance of document-node() rather than (the perhaps
more natural) root().

keys are restricted to documents and temporary trees (both of which
always have a document node as root)

other edge casses involving parentless attribute nodes:

   The XDM data model does not permit an attribute node with no parent
   to have a typed value that includes a namespace-qualified name, that
   is, a value whose type is derived from xs:QName or xs:NOTATION. This
   restriction is imposed because these types rely on the namespace
   nodes of a containing element to resolve namespace
   prefixes. Therefore, it is an error to validate a parentless
   attribute against such a type. 

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--