Re: [xml] Re-using an xmlDtd

Date view Thread view Subject view Author view

From: Daniel Veillard (Daniel.Veillard@imag.fr)
Date: Tue Jan 02 2001 - 11:15:57 EST


On Mon, Dec 11, 2000 at 05:38:32PM -0800, Joe McAlerney wrote:
>
> I originally dealt with this issue by creating an external subset via
> xmlNewDtd, manually connecting the two together with the doc->extSubset,
> dtd->doc, and dtd-parent pointers, then disconnected everything when I
> had to free the xmlDoc. That worked fine until I needed to include the
> DOCTYPE declaration tag in the XML document.
>
> I followed some relevant conversation between Daniel and Kenneth
> Pronovici titled "Generating XML including <!DOCTYPE> external
> reference" and "Bug #21194" to successfully add the DOCTYPE tags to my
> XML documents. Unfortunately, this makes it more difficult to re-use
> the DTD, as it becomes a child of the xmlDoc itself.
>
> I've already written an xmlAddIntSubset() function to connect an
> existing Internal Subset to an existing xmlDoc, and I'm about to start
> writing a function to cleanly remove the Internal Subset. Before I do
> this, I wanted to see if I'm re-inventing the wheel. Does anyone else
> have a better way to re-use a xmlDtd so that it does not have to be
> recreated every time an xmlDoc is?

  Just found your mail while browsing the mail backlog I have
accumulated over December.
  If you have coded those two functions, I would be
interested to look at them for possible inclusion.

Daniel

-- 
Daniel Veillard      | Red Hat Network http://redhat.com/products/network/
daniel@veillard.com  | libxml Gnome XML toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
----
Message from the list xml@rpmfind.net
Archived at : http://xmlsoft.org/messages/
to unsubscribe: echo "unsubscribe xml" | mail  majordomo@rpmfind.net


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:44:34 EST