Hi,

I asked the same question a while ago and spent loads of time 
researching it so I'll communicate what I found here to save you some 
time, perhaps.

Dom4j will of course parse any valid XML document, an a schema is valid 
XML.  However there is a lot more to it, if you actually want your 
program to understand the schema in a way that you can display it in a 
JTree, for example.  The dom4j folks suggested the MSV library, but 
conversations here and over at the MSV mailing list proved that it 
wouldn't work for what we wanted.  In our case, we wanted cardinality 
info as well as all the addtional info/constraints stored by the Schema.

We finally implemented code which is now in production that uses the 
Castor library.  I can't remember but I think it is from IBM.  Anyway, 
it let us walk the schema and grab all the info we wanted as we went.

Have fun

Arati wrote:

>Hi everybody
>
>My requirement is to parse an XML schema document and represent the
>structure of the XML as a JTree in Swing. For that purpose I want an API
>that would parse an XML schema document for me,something similar to wutka
>parser for DTD.
>
>Can I use dom4j for the same and if so, how to go about it? Its use was not
>very clear to me from the API.
>
>Thanks in advance,
>Arati
>
>
>
>-------------------------------------------------------
>This sf.net email is sponsored by:ThinkGeek
>Welcome to geek heaven.
>http://thinkgeek.com/sf
>_______________________________________________
>dom4j-user mailing list
>[EMAIL PROTECTED]
>https://lists.sourceforge.net/lists/listinfo/dom4j-user
>
>
>  
>


-- 
Brian W. Young
Senior Software Engineer/Project Manager
1309 Sutton Park Drive South, Suite 320
Jacksonville, FL 32224
[EMAIL PROTECTED]
voice: 904.482.4209
fax:   904.482.4220




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
dom4j-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dom4j-user

Reply via email to