• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

XML Parsers

 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need some details...with respect to the XML parsers listed below.

Out of these Parsers which one is good and why we need to go for it
(SAX, DOM, STAX,JAXP, Digester)


Advantages and disadvantages.. (Like STAX is good for parsing but in case of validation it doesn�t support schema � it supports schema but with the help of XMLBeans )

Basically I want to accomplish tasks like


1. Convertion of XML to Object
2. Object to XML
3. Validate xml with Schema

Thanks
Bala
 
Ranch Hand
Posts: 2308
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Originally posted by Balachandar Nayak:

Out of these Parsers which one is good and why we need to go for it
(SAX, DOM, STAX,JAXP, Digester)



My understanding of the above mentioned stuffs.

SAX,DOM are two processing models within JAXP only.Even STAX is also included starting JAXP 1.3 that gets shipped with JDK1.5 onwards.

Digester is rule based parsing , specifically good for parsing of configuration files for projects and stuffs where you need rule based parsing and frequent changes to XML model.

I think JAXP 1.3 onwards validation process has be separated out from parsing , so you can use validation of it.

And regarding your other requirement , I think you need JAXB (google for castor) , or XMLBeans.

Hope this helps,
 
Screaming fools! It's nothing more than a tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
    Bookmark Topic Watch Topic
  • New Topic