xsl-list
[Top] [All Lists]

[xsl] Incremental Update: change a portion of the XML and the XSLT operates on just that portion

2010-01-20 10:25:45
Hi Folks,

On page 987 of the book, "XSLT 2.0 and XPath 2.0" the author Michael Kay 
discusses the advantages of functional programming. One of the main benefits, 
he argues, is the ability to do incremental updates. Here is a paragraph that 
really captured my interest:

------------------------------------------------------
We want to get away from static pages; if you're showing a map of traffic 
congestion hotspots in your area, then when the data for a particular road 
junction changes, you want the map updated in real time, and it should be 
possible to do this without recalculating and redrawing the whole map. This is 
possible if there's a direct relationship--a function--between what’s shown at 
a particular place on the map display and a particular data item in the 
underlying database. So if a program is decomposed into a set of smaller, 
independent functions, each relating one piece of the output to one piece of 
the input, then we have the potential to do this on-the-fly updating.
------------------------------------------------------

Wow!  I want to do that.  But how?

Suppose that I have an XML document and an XSLT transform. The XSLT transform 
processes the entire document and outputs, say, an HTML document. Later, I 
update one portion of of the XML document. How do I get the XSLT to operate on 
just the updated portion? And how does the XSLT update just the relevant 
portion of the HTML document?

/Roger
--~------------------------------------------------------------------
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>
--~--

<Prev in Thread] Current Thread [Next in Thread>