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

Re: [xml] Using xml catalogs



On Mon, Mar 29, 2004 at 02:38:30PM +0200, Petr Novak wrote:
> >   Well, you don't use the local catalog, it's not that libxml2
> > doesn't handle it, it's that you make no use of it apparently.
> > xmlCatalogDump() dumps the global catalog, not the one which may
> > be used for the specific document. And without any DOCTYPE in your
> > instance I can't see how you expect the local catalog to have any
> > use.
> 
> If it is in the local catalog, how I can get the pointer on it? 
> For xmlACatalogDump() I need some xmlCatalogPtr as a parameter.
> I see to docs and the one methods to get it is xmlLoadACatalog(),
> but it need the name of the file with the xml catalog.
> 
> I have no DOCTYPE in my document, because I'm using RelaxNG for
> the validation.

  The local catalog is only used during parsing/DTD validation.
There is no pointer from the parsed document to the local catalog,
it's only attached to the parser context during the parsing/DTD validation
phase, and destroyed with the context. Using a lower level API
you could have access to the context and preserve the catalog from
being destroyed 
      void              *catalogs;       /* document's own catalog */

Daniel

-- 
Daniel Veillard      | Red Hat Network https://rhn.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]