XML Scripting and XSLT

XML scripting is one of the main motivations for JudoScript itself. JudoScript supports SAX and DOM programming and XSL transformation. In the do..as xml event-driven statement, SAX events, including tags, are denoted as labels, followed by handler code. JudoScript extends SAX with a text tag, which is a compound tag that includes the opening, closing tags and the text enclosed within. The opening tag's attributes are accessible, too. If a tag has mixed content, you have the option to copy or ignore all the embedded tags. For each event, the built-in variable $_ represents the tag or the event. XML data can be read into a DOM by the do..as dom expression, which returns an org.w3c.dom.Document object. You can use a function variable as a node filter when using the Java DOM traversal API. To create a DOM, use system functions createDom(). The xslt statement applies XSL transformations and also copies XML documents and outputs files or DOMs.