streaming transformations for xml (stx) is an xml transformation language intended as a high-speed, low memory consumption alternative to xslt version 1.0 and 2.0. current work on xslt 3.0 includes streaming capabilities. == 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. == specifications == stx's query language is called stxpath and is based on xpath 2.0. 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 == * stx home page * an introduction to streaming transformations for xml
XML-based_standards