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

Re: Diagramming XSLT

Subject: Re: Diagramming XSLT
From: Torsten Schassan <schassan@xxxxxx>
Date: Wed, 16 Apr 2008 12:57:19 +0200
Re:  Diagramming XSLT
Hash: SHA1


coming back to one "older" thread:

When I explain XML/XSLT to non-programmers (and sometimes even computer
illiterates) quite regularly, I consider three views helpful, especially
taking into consideration Wendell's statement:

> As for how to approach it, if what you're trying to get across is the
> processing model and the basic notion of matching templates and
> generating results, diagrams may actually be a hindrance, since the
> "flow" of the stylesheet as it matches one node and then another is
> going to be quite complex on anything but the most trivial and
> unrepresentative cases. People's brains don't recurse well past about
> four levels without help (even those of us who like the idea of
> recursion). We're much better with iteration.

The views are:

1. XML/XSL is organized like a "matrushka" (everything nests; showing an
image of a matrushka might be visualization enough!). You can organize
both content and processing this way. Processing the xslt means to
(virtually) nest the templates (called ex- or implicitely). Thus you
only need to show two levels, the rest is up to imagination.

2. Look at the XML/XSLT file like a SAX parser would do: reading a start
tag means to open another (matrushkanian) level (XML) or to apply
another template (XSL). Reading a closing tag means to get back to the
last level.

3. Look at the XML/XSLT file like a DOM parser would do: Traverse the
tree applying two rules: a) go left as far as you can; b) if a) is not
possible go back until you find a sibling, go right and apply rule a)
again. That sometimes things are stored in variables or params and taken
with them on the way shouldn't increase the difficulties to understand
the paradigm to much.

If you find this helpful and a way to visualize it, please let us know. ;-)

Best, Torsten

- --
Torsten Schassan
Herzog August Bibliothek, Postfach 1364, D-38299 Wolfenbuettel
Tel.: +49-5331-808-130, schassan {at} hab.de
http://www.hab.de; http://www.hab.de/forschung/projekte/weiss64.htm
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


Current Thread


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.
First Name
Last Name
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.