IMPORTANT:
this is not a Support Forum! Experienced users might answer from time to time questions posted here. If you need a professional and reliable answer, or if you want to report a bug, please contact Altova Support instead.

Hi i am very new to xsd plz help me Options · View
raov
Posted: Monday, April 2, 2007 7:22:11 AM
Rank: Newbie

Joined: 4/2/2007
Posts: 2
Location: Bangalore
Hi I am very new to xsd please help me.
my requirement is I want to run part of xsd file, means
I have an xsd file.
<xs:schema targetNamespace="http://openuri.org/easypo"
xmlns:po="http://openuri.org/easypo"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified">

<xs:element name="purchase-order">
<xs:complexType>
<xs:sequence>
<xs:element name="customer" type="po:customer"/>
<xs:element name="line-item" type="po:line-item" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="shipper" type="po:shipper" minOccurs="0"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:complexType name="customer">
<xs:sequence>
<xs:element name="name" type="xs:string"/>
<xs:element name="address" type="xs:string"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="line-item">
<xs:sequence>
<xs:element name="description" type="xs:string"/>
<xs:element name="per-unit-ounces" type="xs:decimal"/>
<xs:element name="price" type="xs:double"/>
<xs:element name="quantity" type="xs:int"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="shipper">
<xs:sequence>
<xs:element name="name" type="xs:string"/>
<xs:element name="per-ounce-rate" type="xs:decimal"/>
</xs:sequence>
</xs:complexType>
</xs:schema>

In the above xsd file have three complex types customer, line-item and shipper. I need to run only customer complex type no need to run entire xsd file. Is there any way to do like my requirement? plz let me know is there any way or not if is it possible then reply to me how can I solve my problem. Plz reply ASAP.
paul
Posted: Wednesday, April 4, 2007 8:21:40 AM
Rank: Advanced Member

Joined: 9/9/2005
Posts: 483
Location: AT
Hello,

What exactly do you mean when you say 'run'? What process are you attempting here? Please go into as much detail as possible...
raov
Posted: Monday, April 9, 2007 1:07:23 PM
Rank: Newbie

Joined: 4/2/2007
Posts: 2
Location: Bangalore
Hi Paul,
Hi Paul,

I am using xml beans whenever I am compiling above xsd file the xml bean software generating the interfaces and implementation classes for every complex type like in the above xsd file customer, line-item, shipper are 3 complex types, then I got there interfaces and implementation classes. But my requirement is I need to generate only customer related beans, no need to generate remains like line-item and shipper. Ultimately my requirement is I need to compile part of xsd file means in my example need to compile only customer complex type. Is there any possibility to use or compile part of xsd file. Please let me know ASAP.

Thanks
raov

paul
Posted: Wednesday, April 18, 2007 7:04:32 AM
Rank: Advanced Member

Joined: 9/9/2005
Posts: 483
Location: AT
Hello Raov,

As I understand it then, you are generating code (using XMLSpy) for your schema, but just require some sections of it?

That being so, it may be possible to be selective about what classes are generated by editing the SPL templates, but probably the quickest/simplest thing would be to manually extract only the elements you need into a separate file and generate code from that.
Users browsing this topic
guest

Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Use of the Altova User Forum(s) is governed by the Altova Terms of Use.