• 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
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

Looking for a free XML to DOM loader

 
Trailboss
Posts: 22954
IntelliJ IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have an XML document that I want to mash into my own custom object set. Rather than do all the parsing myself, I'm thinking it would be wise to read it into a DOM tree and then go through DOM to make my own object tree.
I seem to recall that there is something free out there. Was it from IBM? Anybody have a URL?
 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u can go for DOM parser.
check out www.w3c.org
alagan
 
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul
check out the sun site
http://java.sun.com/xml/
for Java API for XML parsing(JAXP) as well as Tutorial for XML and JAXP. I found the tutorial excellent and a must for all those wanting to use XML. Though there are many parsers in the market I think that using a parser that is Java product is best. JavaWorld also has some excellent articles using JAXP and DOM.
Regds.
Rahul

[This message has been edited by Rahul Mahindrakar (edited August 13, 2000).]
 
paul wheaton
Trailboss
Posts: 22954
IntelliJ IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I looked at the sun site and saw the words "reference implementation" and got spooked. Has anyone fiddled with it? I suspect that it isn't about to become part of something like java.xml.* - or is it?
Someone else directed me to xml.apache.org, where you can find something called xerces - apparently that is the former IBM Java XML loading tool handed over to apache. Supposed to be good stuff. Any comparisons?

 
Rahul Mahindrakar
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul ,
Project X was the name given to what JAXP is today. Project X is the beta version at sun's hand at XML technology. JAXP is now an extension package with the javax.xml.parsers etc. naming.
Reference implementation!! one more term. I checked it out.
For a specification to be complete there should be
1) A final specification
2) Reference Implementation which demonstrates the capabilities of the API and also provides an operational definition of the specification.
Thus Reference Implementation is not bad!! .
JAXP has first defined the specification in Version 1
now it has moved ahead and providing a Reference implementation in 1.0.1 which is good!!
 
Ranch Hand
Posts: 213
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul,
I'd suggest trying out either IBM's XML4J parser or Apache's Xerces.
 
paul wheaton
Trailboss
Posts: 22954
IntelliJ IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What do you think will be the dominant parser in two years? The Sun stuff or the apache stuff?
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My crystal ball is pretty cloudy right now when tuned to 2002. The JAXP package works and is one of the most compliant with the XML standard. The Tomcat server is using JAXP.
Actually it turns out that only a few calls are ever specific to a particular parser - most of the time you can work with the org.w3c.dom interface specification as far as navigating through a DOM in memory. JAXP has the sun specific classes nicely separated from the standard interfaces.
The advantage of using the Apache project Xerces parser is that then you can play with the Xalan XSLT processor which is totally cool.
Bill
 
Junaid Bhatra
Ranch Hand
Posts: 213
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul,
I would definitely go with the Apache stuff, although it's very difficult to say what's gonna happen 2 years down the line.
The last time I looked at JAXP (which was very recent), it was not SAX2 compliant (it only supported SAX1). However both Xerces and XML4J are now SAX2 compliant. I believe a lot of work is going on in Apache right now, and it has a strong backing from IBM.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!