Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » XML Schema Definition (XSD) » how to modify the XSD using the Xpath
how to modify the XSD using the Xpath [message #582532] Tue, 13 January 2004 07:18
mahesh is currently offline maheshFriend
Messages: 2
Registered: July 2009
Junior Member
HI all,

Can any one help me to solve the problem of
solving this problem
listed below..

1)My requirement is to modify the XSD file by using
the XPath.
2)XPath will be in terms of the element name and
not it terms of element.

for Example

The XSD file will look like this

<xs:complexType name=" AuthorsType ">

<xs:attribute name="Name" type="xs:string" use="required"/>

</xs:complexType>


<xs:element name="BookType">
<xs:complexType >

<xs:sequence>

<xs:element ref="Name"/>

<xs:element name="Authors" type="AuthorsType"/>

<xs:element ref="ISBN"/>

<xs:element ref="Publisher"/>

<xs:element ref="Shelf"/>

</xs:sequence>

</xs:complexType>
</xs:element >
<xs:element name="BookStore">

<xs:complexType>

<xs:sequence>

<xs:element ref="BooksType"/>

<xs:element name="Novels" type="NovelsType"/>

<xs:element name="Magazines" type="MagazinesType"/>

</xs:sequence>

</xs:complexType>

</xs:element>



Xpath will be BookStore/BooksType/AuthorType/@name that means BookStore
contains Books of type BooksType and BooksType contains Authors of type
AuthorsType



In the AuthorsType I want to change this attribute of use to optional
<xs:attribute name="Name" type="xs:string" use="required"/>
Previous Topic:use="required"/use="optional"
Next Topic:how to find the element that is refered using ref attribute.
Goto Forum:
  


Current Time: Wed Apr 24 22:40:10 GMT 2024

Powered by FUDForum. Page generated in 0.02780 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top