I have not noticed anybody saying nice things about DOM, so i will. :-)

but please dont take this as flame bait. it's my opinion, and that's all.

i love DOM. i prefer using DOM whenever possible. it's clean, predictable,
simple, orthagonal.

the twisty bits of really making sure that your event handlers work as
they should in all conditions in SAX makes me crazy.

i should state here that i recognize that DOM becomes wildly impractical
if you have huge files, because each DOM tree would consume copious
amounts of RAM, or massive traffic because DOM tree walking is kinda slow.

Of course, huge files AND massive traffic would be *really* exciting, but
not in a good way.... :-)

but absent those constraints, i think DOM is a great place to begin.

and it's supported directly in xerces-c

On Wed, 6 Mar 2002, Ralph Goers wrote:

> I have that book.  It is a good place to start.
> 
> The reason that the SAX2 book is based on Java is that its author is the
> current maintainer of SAX at http://www.saxproject.org/. If you go there you
> will find that the SAX interface is ONLY specified in JAVA. Implementations
> in other languages are simply based on the Java specification.
> 
> Ralph
> 
> -----Original Message-----
> From: Thomas LaCicero [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, March 06, 2002 11:23 AM
> To: [EMAIL PROTECTED]
> Subject: RE: new to Xerces
> 
> 
> Every where I look I see Java classes and Java Docs .. hell even the SAX2 
> book from O'Reilly is based on the JAVA implementation.
> 
> So basically I have a rather long road ahead of me.  The only good news is 
> that I only need certain elements out of the XML string and the format will 
> rarely change .. I actually started writing the tag I need using the Perl 
> regex for C++.
> 
> I have a book on order called C++XML , I am hopping this helps  :)
> 
> Thanks for the info
> 
> 
> At 08:56 AM 3/6/2002 -0800, you wrote:
> >In my opinion, SAX is the way to go.  However, SAX - in my opinion - has
> >some real deficiencies that make it hard to work with, especially in doing
> >what you are trying to do.  Basically, SAX gives you a single
> >ContentHandler.  If you want to turn your XML document into C++ objects
> than
> >you will really want multiple ContentHandlers, each handling their own part
> >of the XML document.  This is somewhat of a pain with SAX.
> >
> >Others have developed somewhat better interfaces to do this, but none of
> >them work with Xerces.  There are many Java implementations of this sort of
> >thing, which is somewhat frustrating when you are trying to do it in C++.
> >
> >I wish someone would come up with SAX3 that allows you to "register"
> >contentHandlers for specific sub-elements.  One package I found that
> sort-of
> >does this is called xmlio, but it is based on expat, and isn't exactly what
> >is wanted either.
> >
> >-----Original Message-----
> >From: Thomas LaCicero [mailto:[EMAIL PROTECTED]]
> >Sent: Wednesday, March 06, 2002 8:45 AM
> >To: [EMAIL PROTECTED]
> >Subject: RE: new to Xerces
> >
> >
> >I did read the FAQs and I am on the way to the book store to pick up a SAX
> >book
> >
> >here is the question .. I am trying to write a C++ program (eventually it
> >will be a CFX tag for cold fusion) to parse an XML string into a C++ data
> >structure (an array even)
> >
> >Am I barking up the wrong tree .. and if not is there any other resources
> >for sample code?
> >
> >
> >Thanks
> >
> >
> >At 05:46 PM 3/6/2002 +0100, you wrote:
> > >We see such questions here yes. But please first read the Xerces C++ FAQ
> >and
> > >a basic DOM/SAX interface reference to avoid the most common questions.
> > >
> > >Regards
> > >
> > >Erik Rydgren
> > >Mandarinen systems AB
> > >Sweden
> > >
> > >-----Original Message-----
> > >From: Thomas LaCicero [mailto:[EMAIL PROTECTED]]
> > >Sent: den 6 mars 2002 16:49
> > >To: [EMAIL PROTECTED]
> > >Subject: new to Xerces
> > >
> > >
> > >I noticed there is a Xerces for Java User list but no
> > >User list for C++
> > >
> > >I have a few questions about using the Xerces API .. can I ask them here?
> > >
> > >
> > >
> > >---------------------------------------------------------------------
> > >To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> > >
> > >---------------------------------------------------------------------
> > >To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to