You are viewing a plain text version of this content. The canonical link for it is here.
Posted to general@xml.apache.org by Matthew Oatham <ma...@hotmail.com> on 2003/05/07 12:28:05 UTC

DOM and DOCTYPE ARRRGGGGHHHHHHHH

Hi,

When parsing an XML file using DOM I need to get information from the 
<!DOCTYPE> element. I can get the public ID and System ID but how do I 
determine if the DTD is of type SYSTEM or PUBLIC. Is there a way?

i.e

<!DOCTYPE test PUBLIC ...

<!DOCTYPE test SYSTEM ...

Thanks.

Matt

_________________________________________________________________
On the move? Get Hotmail on your mobile phone http://www.msn.co.uk/mobile


---------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          general-unsubscribe@xml.apache.org
For additional commands, e-mail: general-help@xml.apache.org


Re: DOM and DOCTYPE ARRRGGGGHHHHHHHH

Posted by "J.Pietschmann" <j3...@yahoo.de>.
Matthew Oatham wrote:
> When parsing an XML file using DOM I need to get information from the 
> <!DOCTYPE> element. I can get the public ID and System ID but how do I 
> determine if the DTD is of type SYSTEM or PUBLIC. Is there a way?

I don't think so.
Why don't you just study the API docs of your DOM implementation?
It's not all that voluminous, and if there is no such functionality,
well, then you are out of luck.
Then there is also the spec at
  http://www.w3.org/DOM/
and the XML-DEV list
  http://www.xml.org/xml/xmldev.shtml

J.Pietschmann


---------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          general-unsubscribe@xml.apache.org
For additional commands, e-mail: general-help@xml.apache.org


Re: DOM and DOCTYPE ARRRGGGGHHHHHHHH

Posted by Kerstin Kohl <kk...@gmx.de>.
Hi,

I assume that You ar talking about Xerces c++ so You can use the method
getSystemId()   to get the system identifier of the external subset. (XMLCh * ) 

Kerstin 

> Hi,
> 
> When parsing an XML file using DOM I need to get information from the 
> <!DOCTYPE> element. I can get the public ID and System ID but how do I 
> determine if the DTD is of type SYSTEM or PUBLIC. Is there a way?
> 
> i.e
> 
> <!DOCTYPE test PUBLIC ...
> 
> <!DOCTYPE test SYSTEM ...
> 
> Thanks.
> 
> Matt
> 
> _________________________________________________________________
> On the move? Get Hotmail on your mobile phone http://www.msn.co.uk/mobile
> 
> 
> ---------------------------------------------------------------------
> In case of troubles, e-mail:     webmaster@xml.apache.org
> To unsubscribe, e-mail:          general-unsubscribe@xml.apache.org
> For additional commands, e-mail: general-help@xml.apache.org
> 

-- 
+++ GMX - Mail, Messaging & more  http://www.gmx.net +++
Bitte lächeln! Fotogalerie online mit GMX ohne eigene Homepage!


---------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          general-unsubscribe@xml.apache.org
For additional commands, e-mail: general-help@xml.apache.org