Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » Getting elements II
Getting elements II [message #585693] Fri, 16 April 2004 20:33
Eclipse UserFriend
Originally posted by:

I would like to ask a follow-up question concerning the "attached" posting:
If I traverse xsd to construct the element list, I have to solve all schema
choice and derivation by myself, right ? The getContentType will just
the above particles, isn't it!?

Subject: Re: Getting elements
From: (Ed Merks)
Organization: EclipseCorner
Date: Mar 02 2004 07:15:58
References: 1


A complex type t only has a t.getContentType() which is a particle if
t.getContentTypeCategory() is element-only or mixed. A particle has a term
which may be an element, a wildcard or a model group, where a model group
more particles recursively. The root particle of a complex type will be a
sequence model group. There is no flat list of element declarations in the
complex type, there's only it's content model represented as a tree of

Michael Norton wrote:

> I must be looking at something completely wrong because this can't be that
> tough. I'm attempting to populate a tree viewer with the elements
> declared in a schema. I can use the getElementDeclarations method to
> retrieve global element(s), but how do I retrieve the elements from, say,
> a complex type global element? I've chased through particles and models,
> but can find no method equivalent to getElementDeclarations (or even
> getElementDeclaration) for these components. Can anyone set me on the
> right path?
Previous Topic:Problem with transferring a type definition between two schemas
Next Topic:Getting elements II
Goto Forum:

Current Time: Fri Oct 30 19:58:59 GMT 2020

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

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

Back to the top