Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > searching xsd for certain types

Thread Tools

searching xsd for certain types
Posts: n/a

I am new to xsd, any help is greatly appreciated. I will have
customers define xsd. In there they will designate an attribute to be
of certian type (e.g some:transid). When I see this in the xsd I have
to create that attribute (if not already exists) and assign transaction

XSD look something like :
<xs:schema xmlnss=""
<xs:element name="Item" >
<xs:attribute name="transaction_id" type="some:transid"

customer defined xml looks like:

<Item name="whatever name">

I add this attribute

<Item name="whatever name" transaction_id="12345678">

This is a made up example, but convey the point. The problem is I dont
know how to search xsd for attributes of type some:transid. I can have
them set type="some:transid". Customers can declare this at root node
or any sub node. I can parse the DOM tree figuring out each attribute
value of every node to see if there is a type=some:transid. But this
will kill me when the document is large. I am assuming there is a
better way to search xsd for attributes/element of certain type. Any
better ways to do this ?.



Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can XSD simple types be derived from complex types? Soren Kuula XML 2 12-01-2005 07:51 PM
XML + XSD: Is it possible to get all errors against the XSD? Markus Java 1 11-22-2005 02:53 PM
xsd:any as a child of xsd:all Peter Aberline XML 0 04-05-2004 03:38 PM
referencing another XSD file within an XSD file XML 1 01-14-2004 05:22 PM
XSD document for XSD defintion Rick Razzano XML 1 09-26-2003 12:41 AM