Sun have had SAX and DOM APIs for XML Parsing for some time. Now, there are a number of new standards, namely JAXM and JAXP, for XML messaging and parsing respectively. What exactly do these new interface standards achieve, and where do they fit with the APIs that Sun has already?

Brian Ewins

Sun never had SAX and DOM. They are xml.org and W3C parser specs, respectively. JAXP is a layer above these which allows parsers to become 'pluggable'. SAX and DOM left a couple of issues open which led to vendor-specific extensions, e.g. to get the parser in the first place. If you work with JAXP you can switch parser without changing your code, just replace the parser JAR. JAXM is not a standard yet, its a working draft of the 'M Project'. It will standardise later when ebXML solidifies later this year, and is meant to provide an API for reliable XML messaging for business transactions. This is a different layer of abstraction from JAXP, SAX, and DOM (level 1), which are all about parsing. JAXM fits in with JAXP in the same way that your own application would: you can switch parsers and JAXM will still work, because it uses JAXP.

0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact