xml-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gus Heck <gus.h...@olin.edu>
Subject Re: How do I parse a DTD in Java?
Date Tue, 13 Jan 2004 17:39:44 GMT
You could extract a copy of the DTD by inspecting the input before you 
parse it and write your own DTD parser... I don't personally know of 
software that parses DTD's directly though, Google of "parse a DTD" 
shows that there is a perl module for this sort of thing I think:

http://search.cpan.org/~phish/XML-LibXML-1.53/lib/XML/LibXML/Dtd.pod

and a java lib:

http://www.wutka.com/dtdparser.html

I also saw something that seemed to talk about a C lib for it in that 
search....

Google knows all :)

-Gus

Andrews, Scott wrote:

>I think you may misunderstand my question?  I'm looking to parse the DTD
>- not the XML.
>
>  _____  
>
>Scott Andrews
>Principle Software Engineer
>Concurrent Technologies Corporation
>(814) 269 6580 (Monday, Wednesday, Friday)
>(814) 632 9559 (Tuesday, Thursday)
>(814) 880 8522 (Cell)
> 
>
>-----Original Message-----
>From: Paul Libbrecht [mailto:paul@activemath.org] 
>Sent: Tuesday, January 13, 2004 11:35 AM
>To: general@xml.apache.org
>Subject: Re: How do I parse a DTD in Java?
>
>Many many many possibilities:
>- JDOM
>- DOM
>- SAX
>- Commons Digester
>- .... just about ten thousand more...
>
>Really don't need JAXB there which is artillery for people fearing to 
>look at XML, to my taste.
>
>Paul
>
>
>On 13-Jan-04, at 16:42 Uhr, Andrews, Scott wrote:
>
>  
>
>>I need something dynamic, where the structure of the XML document is
>>unknown until parse time, as if the user specifies the DTD.  I want
>>    
>>
>to,
>  
>
>>at run-time, iterate over the structure and provide the user with
>>actions to be taken when those elements are encountered in the XML
>>documents.
>>    
>>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: general-unsubscribe@xml.apache.org
>For additional commands, e-mail: general-help@xml.apache.org
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: general-unsubscribe@xml.apache.org
>For additional commands, e-mail: general-help@xml.apache.org
>
>  
>



---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@xml.apache.org
For additional commands, e-mail: general-help@xml.apache.org


Mime
View raw message