Re: [xml] memory usage question
- From: Daniel Veillard <veillard redhat com>
- To: Stefan Kost <ensonic hora-obscura de>
- Cc: xml gnome org
- Subject: Re: [xml] memory usage question
- Date: Wed, 17 Aug 2005 12:06:59 -0400
On Wed, Aug 17, 2005 at 05:53:37PM +0200, Stefan Kost wrote:
Hi Daniel.
<snip>
The dictionnary is used by default if one use the new xmlReadxxx APIs.
Daniel
Does xmlParseDocument(ctxt) use the dictionary. If looked over the
sources, but found no easy answer.
depends how ctxt was built ! xmlReadxxx call xmlParseDocument !
If you call xmlParseDocument() directly, then I'm sorry you're attacking
at the lowest publicly available level of the API and there is no easy
answer. In general you should not call something like xmlParseDocument()
directly unless you have a good knowledge of libxml2 internal processing.
IIRC teh dictionnary is used if ctxt->dict() has been created and the
parser is running in version2 mode.
I noticed one thing. Inside parser.c several methods call
xmlParseDocument(ctxt). These methods call xmlDetectSAX2(ctxt) before,
which is something xmlParseDocument(ctxt) does too at the beginning.
Maybe be extra calls can be spared.
Cost is low, and I fear troubles doing so.
Regarding wheter it used dictionaries I've also used the site search:
http://www.xmlsoft.org/search.php?query=xmlParseDocument+dictionary&scope=any&submit=Search+...
Does this support operators like AND (search for documents having both
keywords).
No it will use both word but not force an AND.
Could you please add a note to the search form to tell the
user either how to specify operators or that there are't any.
There is no operator, why would you assume there is one ? If you want to
add operators search.php is in libxml2 doc CVS subdir !
Daniel
--
Daniel Veillard | Red Hat Desktop team http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]