Streaming Transformations for XML

Streaming Transformations for XML

Streaming Transformations for XML (STX) is an XML transformation language intended as a high-speed, low memory consumption alternative to XSLT.

Overview

STX is an XML standard for efficient processing of stream-based XML. As we will discover, XSLT is not well suited to stream based processing, and STX fills this niche.

Conventional XML processing involves loading the entire XML document into memory for use. This is as opposed to SAX which streams XML events such as "open element" "close element" "text node" (and so on) so that other software that can begin interpreting these immediately -- before the end of the file is reached. Unfortunately some software can't effectively use XML fragments this way and must build up the whole document to begin processing. So is the case with XSLT. Because XSLT's XPath can select any node throughout the document it must have the entire document available in memory. Understandably, this could be perceived as a bottleneck.

STX only allows queries immediately surrounding the current node so it can quickly start transforming and outputting SAX event nodes as they arrive. As it can discard nodes immediately after processing the memory use is significantly lower than that of XSLT. Having a limited query scope is a defining characteristic of STX.

This architectural decision intentionally marginalises STX as a niche language. Indeed, it would be wrong to say that STX is a general purpose transformation language; however, if your transformation needs can be met by STX then it's an efficient and smart choice.

Standards

STX's query language is called STXPath.

Implementations of STX are available in Java and Perl.

Similar projects

Unlike STX which is declared using an XML syntax, these two projects associate SAX events with callback functions:

* Xineo OAX
* SAX Adapter

External links

* [http://stx.sourceforge.net/ STX home page]
* [http://www.xml.com/pub/a/2003/02/26/stx.html An Introduction to Streaming Transformations for XML]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем решить контрольную работу

Look at other dictionaries:

  • Streaming Transformations for XML — Streaming Transformations for XML, kurz STX, ist eine Programmiersprache zur Transformation von sehr großen XML Dateien. STX verbindet das Abstraktionslevel von XSLT mit der Performance von SAX, insbesondere dem niedrigen Speicherbedarf von SAX… …   Deutsch Wikipedia

  • Java API for XML Processing — The Java API for XML Processing, or JAXP (pronounced jaks p ), is one of the Java XML programming APIs. It provides the capability of validating and parsing XML documents. The three basic parsing interfaces are: * the Document Object Model… …   Wikipedia

  • Java API for XML Processing — Das Java API for XML Processing, oder JAXP, ist eines der Java XML APIs. Es handelt sich um ein leichtgewichtiges standardisiertes API zum Validieren, Parsen, Generieren und Transformieren von XML Dokumenten. Die jeweilige (nicht standardisierte) …   Deutsch Wikipedia

  • XML transformation language — An XML transformation language is a computer language designed specifically to transform an input XML document into an output XML document which satisfies some specific goal.There are two special cases of transformation: * XML to XML : the output …   Wikipedia

  • .xml — Vorlage:Infobox Dateiformat/Wartung/magic fehltVorlage:Infobox Dateiformat/Wartung/website fehlt Extensible Markup Language Dateiendung .xml …   Deutsch Wikipedia

  • XML — Vorlage:Infobox Dateiformat/Wartung/magic fehltVorlage:Infobox Dateiformat/Wartung/website fehlt Extensible Markup Language Dateiendung …   Deutsch Wikipedia

  • Xml — Vorlage:Infobox Dateiformat/Wartung/magic fehltVorlage:Infobox Dateiformat/Wartung/website fehlt Extensible Markup Language Dateiendung …   Deutsch Wikipedia

  • Langage de transformation XML — Un langage de transformation XML est un langage de programmation créé spécifiquement pour créer toute forme de document en sortie à partir d un document XML en entrée. Il y a deux cas spécifiques de transformation : XML vers XML : le… …   Wikipédia en Français

  • Langage De Transformation XML — Un langage de transformation XML est un langage de programmation créé spécifiquement pour créer toute forme de document en sortie à partir d un document XML en entrée. Il y a deux cas spécifiques de transformation : XML vers XML : le… …   Wikipédia en Français

  • Langage de transformation xml — Un langage de transformation XML est un langage de programmation créé spécifiquement pour créer toute forme de document en sortie à partir d un document XML en entrée. Il y a deux cas spécifiques de transformation : XML vers XML : le… …   Wikipédia en Français

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”