Re: [Libxmlplusplus-general] Replacing Tree and Parser with DomParser and SaxParser



On Tue, 2002-11-12 at 14:51, Christophe de Vienne wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> Le Mardi 12 Novembre 2002 14:04, Murray Cumming a écrit :
> > On Tue, 2002-11-12 at 11:03, Christophe de Vienne wrote:
> > > -----BEGIN PGP SIGNED MESSAGE-----
> > > Hash: SHA1
> > >
> > > Le Mardi 12 Novembre 2002 10:49, Murray Cumming a écrit :
> > > > The Tree seems to be a wrapper for the DOM parser functionality, and
> > > > the Parser seems to be a SAX parser.
> > >
> > > Right
> > >
> > > > I plan to rearrange this as DomParser
> > > > and SaxParser classes.
> > >
> > > Ok
> >
> > I have committed the first stage of that, along with an examples
> > directory so we can test whether this stuff actually works.
> 
> Looks great...
> I guess you're going to herit saxparser from parser too ?

Yes. I'm hoping to find common functionality to put in the base class.
libxml doesn't seem to have a clear distinction between DOM and SAX in
the API.

> Why do you think about adding a "parse_buffer(const str::string &)" method to 
> parser ?

Seems sensible.

>  I think a virtual parse_buffer(const char *) will be necessary too, 
> to avoid useless buffer copy when parsing a char * buffer.

That's optimisation. And it's too early for optimisation. You might add
a comment about it.

-- 
Murray Cumming
murray usa net
www.murrayc.com





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]