Hi,

while converting my app from Qt library XML parser to Xerces-C 2.6, I am 
confused with spec. proc. instruction.

1) In Qt, only one way to set XML version or encoding is via creating proc. 
instruction <?xml version = '...' encoding = '...' ?>. In Xerces, this 
possible too, but also there are functions DOMDocument::  
setEncoding/Version/Standalone.

What way is preferred ?

2) When I parse simple XML:

<?xml version = '1.0' encoding = 'UTF-8' standalone= 'yes' ?>
<root/>

Special procesing instruction is not listed when I use:

DOMNode * pChildNode = pDoc->getFirstChild();
while ( pChildNode != NULL )
{ 
        pChildNode = pChildNode->getNextSibling(); 
}

It is right behavior ?

3) When I create spec. XML processing instruction in document and save it, I 
get unwanted output:

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<?xml version = '1.0' encoding = 'UTF-8' standalone= 'yes' ?>
<kkk/>

I am assume that replies are:
1) use functions
2) XML spec. proc. instruction is not accssible
3) I must disallow user to create proc. instruction named xml.

It's right ?
Lumir Vanek
KXML Editor developer
http://www.valachnet.cz/lvanek


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to