Subject: Re: How to distinguish b/n a scalar and a node-set having a single text node? From: Mike Brown <mike@xxxxxxxx> Date: Mon, 23 Oct 2000 13:13:34 -0600 (MDT) |
Dimitre Novatchev wrote: > I am trying to determine whether the value of a parameter is a scalar > or a node-set, and to do so without using extension functions (I > consider node-set() to be "standard", as it will be in XSLT 1.1). > > The only problemetic case is: > How to determine whether what seems to be a node-set having a single > text node is actually a node set or whether it is a scalar (the value > of the text node). A parameter is going to be one of the 4 object types in XPath: boolean, number, string, node-set, or the object type introduced in XSLT: result tree fragment. There is no concept of 'scalar'. I don't think there is a way to test for the type of object. The few operations that are permissible on any type of object do not provide helpful info. - Mike ____________________________________________________________________ Mike J. Brown, software engineer at My XML/XSL resources: webb.net in Denver, Colorado, USA http://www.skew.org/xml/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
How to distinguish b/n a scalar and, Dimitre Novatchev | Thread | Matching elements with a name speci, SCOTT, Darren, FM |
Re: unknown element selection (pare, John E. Simpson | Date | Re: A very simple question, Mike Brown |
Month |