Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » Creating complexType with simpleContent
Creating complexType with simpleContent [message #595530] Wed, 08 June 2005 17:43
Dave Carlson is currently offline Dave CarlsonFriend
Messages: 402
Registered: July 2009
Senior Member
I'm trying to construct a schema via the API, where a complexType extends a
simpleType (maybe indirectly via another complexType with simpleContent). I
can't get the output XSD file to produce <simpleContent> in that

For example, a small excerpt from OAGIS 8.0 schema:

<xs:complexType name="Name">
<xs:extension base="LingualString"/>

<xs:complexType name="LingualString">
<xs:extension base="xs:string">
<xs:attribute name="lang" type="xs:language"/>

Reviewing the example, simpleContent is produced
only by adding an anonymous simpleType as content. I tried setting the
contentTypeCategory directly, but no affect on the generated schema.

complexType.setContentTypeCategory(XSDContentTypeCategory.SI MPLE_LITERAL);

I always get <xs:complexContent> in both of these types, which is incorrect.
Is this a bug? I am using EMF/XSD 2.1 20050428 build.

Dave Carlson
Previous Topic:Adding XML Comments to XML Schema?
Next Topic:Creating complexType with simpleContent
Goto Forum:

Current Time: Mon Jan 18 11:50:37 GMT 2021

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

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

Back to the top