Romilson,
I believe you've got some errors in your xml. You might try using a tool
like XMLSpy to verify that your xml is well-formed before putting it through
the code generator. Try closing the complexContent in the subclass. Also,
the type for jjjjjj needs to be xs:string.
<xs:complexType name='MAINCLASS'>
<xs:attribute name='OID' type='xs:string' use='required'/>
<xs:attribute name='type' type='xs:string' use='required'/>
</xs:complexType>
<xs:element name='SUBCLASS'>
<xs:complexType>
<xs:complexContent>
<xs:extension base='MAINCLASS'>
<xs:sequence>
<xs:element name="jjjjj" type='xs:string'/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
Hope this helps -
Margaret
-----Original Message-----
From: Romilson Cruz de Carvalho [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 03, 2002 11:34 AM
To: [EMAIL PROTECTED]
Subject: [castor-dev] Extension with element not function
Hi .. i have the two complexTypes .. and my need is put the SUBCLASS
complexType as a derivation from
MAINCLASS.
<xs:complexType name='MAINCLASS'>
<xs:attribute name='OID' type='xs:string' use='required'/>
<xs:attribute name='type' type='xs:string' use='required'/>
</xs:complexType>
<xs:element name='SUBCLASS'>
<xs:complexType>
<xs:complexContent>
<xs:extension base='MAINCLASS'>
<xs:sequence>
<xs:element name="jjjjj" type='string'/>
</xs:sequence>
</xs:extension>
<xs:complexContent>
</xs:complexType>
</xs:element>
The code above is not valid .. because the processor said that element name
jjjjj
can not stay in that place.
But .. i need to derive the class SUBCLASS , ,and add a element to
SUBCLASS..
How to do it ?
Thanks.
Romilson
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev
-----------------------------------------------------------
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
unsubscribe castor-dev