RE: Never mind the browser, let's do MicroXML
There's all sorts of glue to hook up XMLStreamWriter to XMLEventWriter to XMLStreamReader to XMLEventWriter Some not so obvious but if you poke around you'll find almost everything you need, and if not I've implemented some missing pieces, just ask. StAXUtils has all this nifty glue http://java.net/projects/stax-utils/ One of many fun functions javanet.staxutils.XMLStreamUtils.copy(XMLStreamReader reader, XMLStreamWriter writer) There's also thead save event pippes, all sorts of adaptors and wrappers, it's a regular christmas party of toys. ---------------------------------------- David A. Lee email@example.com http://www.xmlsh.org -----Original Message----- From: Michael Sokolov [mailto:firstname.lastname@example.org] Sent: Saturday, December 18, 2010 9:15 AM To: Michael Kay Cc: email@example.com Subject: Re: Never mind the browser, let's do MicroXML On 12/18/2010 8:05 AM, Michael Kay wrote: > >> >> PS: probably everyone on this list is already aware of this, but SAX >> stands for Simple API for XML. To support MicroXML, we would want an >> even simpler one; Micro-API: MAX? uAX?. > > Have you tried XMLStreamWriter? As an event-based push API, it's a > delight to use compared to SAX, whether you're sending or receiving. As it turns out I only very recently implemented some xml-aware full-text indexing using woodstox; as you say, I was drawn to it because I needed a pull parser. So I worked with XMLStreamReader. It wasn't obvious to me how to use XmlStreamWriter as an event-base push API. I guess one could implement an event sink as an XmlStreamWriter, but then what? Is there some existing glue to connect a Reader to a Writer, or does one need to implement that? Also, to return to the point in my original post: it wasn't so much a criticism of SAX, as much as to say that folks working with a simplified document format might prefer to have a simplified API that isn't peppered with hooks for legacy (XML 1.0) features. But is it really worth the trouble to produce new micro- versions of all these XML APIs that would simply eliminate CDATA, DOCTYPE, namespaces, etc? Especially if namespaces are to be reintroduced later? -Mike _______________________________________________________________________ XML-DEV is a publicly archived, unmoderated list hosted by OASIS to support XML implementation and development. To minimize spam in the archives, you must subscribe before posting. [Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/ Or unsubscribe: firstname.lastname@example.org subscribe: email@example.com List archive: http://lists.xml.org/archives/xml-dev/ List Guidelines: http://www.oasis-open.org/maillists/guidelines.php
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format