[xml] AW: Changing xmlwriter DTD writing part
- From: "Mickautsch, Alfred" <alfred mickautsch schuler-ag com>
- To: <xml gnome org>
- Subject: [xml] AW: Changing xmlwriter DTD writing part
- Date: Fri, 19 Mar 2004 09:45:29 +0100
Hallo Lucas,
it seems to me, your mail didn't make it to the list...
-----Ursprüngliche Nachricht-----
Von: Lucas Brasilino [mailto:brasilino recife pe gov br]
Gesendet: Donnerstag, 18. März 2004 21:13
An: Mickautsch, Alfred
Cc: xml gnome org
Betreff: Changing xmlwriter DTD writing part
Hi Alfred, and all :)
Can you share your thoughts about this change ?? :))
So I would like to have a possibility to write the start of the
entity with xmlTextWriterStartDTDEntity or some new function,
then write the content with xmlTextWriterWriteString and end it
with an according xmlTextWriterEndDTDEntity function. The problem
lies in the fact, that the structures of internal and external
entities differ a lot and I do not have the slightest idea how
to make it possible in a simple way, to write both of them using
the same start and end function.
I've been looking around xmlWriter's DTD part and it looks
a little obscure :) can you provide me a sample code? My tentatives
wasn't so successful.
But let's go through some ideas: DTD internal declarations
could be stored in a xmlLink list which points to xmlChar buffers.
Each buffer could be an element, attribute list or entities (internal
and external). So, should be provided some functions like:
xmlTextWriterAddDTDElement(xmlTextWriterPtr, xmlChar
*element, xmlChar
*contentmodel);
xmlTextWriterAddDTDAttr(xmlTextWriterPtr, xmlChar *element, xmlChar
*attribute, xmlChar *decl);
xmlTextWriterAddDTDIntEntity(xmlTextWriterPtr, xmlChar
*entity, xmlChar
*content);
xmlTextWriterAddDTDExtEntity(xmlTextWriterPtr, xmlChar
*entity, xmlChar
*uri);
And when calling xmlTextWriterEndDTD(), all declaration buffers should
be serialized. Tell me fellings :)
Well, the currently existing functions are supposed to work somewhat
like that, except they are writing directly to the stream.
Since I did some work to make it possible to write DTD's without
calling xmlTextWriterStartDTD first, I thought, this would be a
good time to make some improvements too.
These changes was applied? If not, can you provide me a patch?
I am working on bug fixes in the DTD part for some weekends now.
If you could wait until monday, maybe I can cleanup the code an make
a patch. I hope there will be an example for using it too.
bests regards
--
[]'s
Lucas Brasilino
brasilino recife pe gov br
http://www.recife.pe.gov.br
Emprel - Empresa Municipal de Informatica (pt_BR)
Municipal Computing Enterprise (en_US)
Recife - Pernambuco - Brasil
Fone: +55-81-34167078
Servus -- Alfred
--
Alfred Mickautsch
schuler business solutions AG
Karl-Berner-Str. 4
D-72285 Pfalzgrafenweiler
tel: +49 (0)74 45 830-184
fax: +49 (0)74 45 830-349
e-mail: alfred mickautsch schuler-ag com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]