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

Re: Doubts regarding XSL and DOM

Subject: Re: Doubts regarding XSL and DOM
From: Paul Prescod <papresco@xxxxxxxxxxxxxxxx>
Date: Thu, 29 Oct 1998 08:18:40 -0600
dom getelementbyname
Amit Rekhi wrote:
> 
> Paul,
> >Object models do not query source trees. Query languages query source
> >trees. XSL has a very simple query language.
> But what if I want to "traverse" my XML source tree from XSL apart from
> "querying" it?

What do you mean by "traverse"? Do you want to process a node elsewhere in
a tree? You can already do that. 

<xsl:process match="foo//*[attribute(bar)]">

> 1) Why not have DOM interfaces along with pattern match syntax to enable
> full XML src. document control?

DOM is an API. It is a way for programming languages to get access to XML
data. XSL is not a programming language. Ergo, DOM is not useful for XSL.

> 2) whether or not there is facility to incorporate DOM interfaces within XSL
> seperate from the query pattern syntax it already has?

There is no such facility for the reason I mentioned above. What would
such a facility look like? 

It could look like this: node.getElementByName( "foo" ) but that would be
embedding *javascript* into XSL, not the DOM. First you need a programming
language. Then you decide what APIs it should have access to. So is your
question whether XSL should have an embedded programming language?

> 3) Does having such a "traversal"  facility go against the design goals of
> XSL? In other words is it something that goes outside the domain of XSL?

XSL has a traversal facility, but has nothing to do with the DOM API.

 Paul Prescod  - http://itrc.uwaterloo.ca/~papresco

Marge: "It's almost as if Snake is killing from beyond the grave."
Lisa: "I warned you that capital punishment wouldn't be a deterrent."
	- The Simpson's halloween special: "Hell Toupee"


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


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.