RE: [xsl] DOM and XML parser

Subject: RE: [xsl] DOM and XML parser
From: "Didier PH Martin" <martind@xxxxxxxxxxxxx>
Date: Fri, 16 Aug 2002 16:31:47 -0400
Hi Jeni,

Jeni said:
Hmm... I wouldn't put it like that. It's true that the syntax of a
pattern is a subset of the syntax of a location path, but a pattern
and an expression do very different things and are used in very
different ways.

Didier replies:
Yes, but let's try to not confuse our fellow. The match attribute's
value is using an Xpath expression subset. Off course the action for a
"match" and a "select" is different. Only the action is, but in both
cases we still use the same language to refer to tree's nodes. An Xpath
subset for a match and the complete xpath 1.0 for the select. This
because we need the template to "match" a single node and the select to
"select" and return either a singleton or a collection of nodes.

Jeni said:
A match pattern is like a regular expression -- you test a node
against a match pattern to see if it matches and what you get is
either yes-it-matches or no-it-doesn't-match. You don't get anything
*returned* from a pattern, and a pattern is only relevant if you
already have a node in mind (the node to which you're applying
templates, for example) and you want to see if the pattern matches
that node.

Didier replies:
Well said jeni. In the abstract, it can be applied to other pattern
match languages like omnimark or DSSSL.

Jeni said:
[Taking the analogy with regexps further, there was an interesting
talk at Extreme which touched on the possibility of getting more
detailed information returned from matching on an XSLT pattern in much
the same way as you might get more detailed information returned from
matching on a regexp, about the submatches within the pattern/regexp.]

Didier replies:
Gee, sound interesting. Its too bad I couldn't be at the conference. It
sounds like a lot of interesting stuff happened there. Do you mean that
more than a boolean value could be returned? Like, for instance, some
info about the node's contained collection, is that it? 

Cheers
Didier PH Martin




 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread