Suitability of XSD for particular task [message #593982] |
Mon, 14 February 2005 22:03 |
Bruno Wassermann Messages: 21 Registered: July 2009 |
Junior Member |
|
|
Greetings XSD'ers.
I have started experimenting with XSD enthusiastically a few days ago,
being convinced that it was the right tool for the task I would like to
outline. A few days later (today) I am not so sure anymore. Before
forgetting about XSD and implementing the below task 'by hand' (querying
DOMs directly), please take a look at what I am trying to achieve and be
so kind to share your thoughts with me as to the suitability of XSD for
this.
THE TASK
(+) We want to parse WSDL files and specifically (surprise) query the XML
Schemas which may be defined in the <wsdl:types> section. [Given that XSD
imports are present in the files, xSD does a great job here.]
(+) From this data, we want to generate a model that is to be displayed in
a tree viewer. We will display a set of <message>s (parsed by a separate
piece of code). Expanding these nodes, we want to display any XSD types
referenced from within the <message> and in turn the types defining these
types. We need a way of differentiating between complex and any of the XSD
simple types.
(+) Furthermore, a type X may reference an element or a type Y in another
(imported) schema. In the tree viewer we want these types (Y, Z, etc.) to
appear as children of X.
(+) Alternatively, a type X may have a complex type definition which
contains an element whose type definition specifies a type in a separate
schema.
I cannot see a straightforward way to achieve; at least XSD doesn't seem
to buy me that much in comparion to generating DOMs of the involved
schemas and turning this information into the desired model
representation.
Please share your wisdom and let me know what you think. Can you see how
to achieve this task with XSD having a serious advantage over a
custom-built piece of code. Let me know if this needs any further
clarification.
Many thanks,
-- Bruno
|
|
|
Powered by
FUDForum. Page generated in 0.04037 seconds