Is it possible to use inheritance in JAXB generated JAVA Classes:
For Example the second Element in the following Schema fragment inherits by
<xs:extension> from the first one:
<xs:complexType name="FileCd">
<xs:annotation>
<xs:appinfo>
<jxb:class implClass="cdFileList.FileCdDerived"/>
</xs:appinfo>
</xs:annotation>
<xs:sequence>
<xs:element name="name" type="xs:string"/>
</xs:sequence>
</xs:complexType>
<xs:complexType name="DirCd">
<xs:annotation>
<xs:appinfo>
<jxb:class implClass="cdFileList.DirCdDerived"/>
</xs:appinfo>
</xs:annotation>
<xs:complexContent>
<xs:extension base="cdl:FileCd">
<xs:sequence>
<xs:element name="childFile" type="cdl:FileCd" minOccurs="0"
maxOccurs="unbounded"/>
<xs:element name="childDir" type="cdl:DirCd" minOccurs="0"
maxOccurs="unbounded"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>
Is there any way to implement this behavior in the defined implClass Classes
like
class DirCdDerived extends FileCdDerived{
...
}
I am getting multiple errors and wonder if this is possible at all.
Thanks
Ralf
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
For additional commands, e-mail: users-help_at_jaxb.dev.java.net