Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » XML Schema Definition (XSD) » choice or sequence min/max occurs
choice or sequence min/max occurs [message #55964] Mon, 06 December 2004 22:09 Go to next message
Eclipse User
Originally posted by: rob.tice.k-int.com

Apologies if this is a trivial problem I just cant see how to get the info.

I am traversing a schema and I have got to the point where I have my XSD
model group. I am using the model group getContents() to traverse the
elements all working okay schema analysis working. However I also need to
know what each choice or sequence has as it min/max occurs so I can properly
understand the relative min/max occurs of the contained elements.

Any help much appreciated.

Rob Tice
Re: choice or sequence min/max occurs [message #56017 is a reply to message #55964] Mon, 06 December 2004 23:08 Go to previous messageGo to next message
Eclipse User
Originally posted by: merks.ca.ibm.com

Rob,

An XSDModelGroup is reached from an XSDParticle, and that is what holds
the min/max occurs. The same model group could be reached by multiple
particles, as for a model group in model group definition that has a
different min/max occurs at each point of reference. So don't expect to
be able to work back from an element declaration or model group to the
particle that references it, since there isn't a unique answer (although
often it will be just the container).


Rob Tice wrote:

>Apologies if this is a trivial problem I just cant see how to get the info.
>
>I am traversing a schema and I have got to the point where I have my XSD
>model group. I am using the model group getContents() to traverse the
>elements all working okay schema analysis working. However I also need to
>know what each choice or sequence has as it min/max occurs so I can properly
>understand the relative min/max occurs of the contained elements.
>
>Any help much appreciated.
>
>Rob Tice
>
>
>
>
Re: choice or sequence min/max occurs [message #56070 is a reply to message #56017] Tue, 07 December 2004 00:50 Go to previous message
Eclipse User
Originally posted by: rob.tice.k-int.com

Thanks Ed

Problem solved


"Ed Merks" <merks@ca.ibm.com> wrote in message
news:cp2opq$osv$1@www.eclipse.org...
> Rob,
>
> An XSDModelGroup is reached from an XSDParticle, and that is what holds
> the min/max occurs. The same model group could be reached by multiple
> particles, as for a model group in model group definition that has a
> different min/max occurs at each point of reference. So don't expect to
> be able to work back from an element declaration or model group to the
> particle that references it, since there isn't a unique answer (although
> often it will be just the container).
>
>
> Rob Tice wrote:
>
> >Apologies if this is a trivial problem I just cant see how to get the
info.
> >
> >I am traversing a schema and I have got to the point where I have my XSD
> >model group. I am using the model group getContents() to traverse the
> >elements all working okay schema analysis working. However I also need to
> >know what each choice or sequence has as it min/max occurs so I can
properly
> >understand the relative min/max occurs of the contained elements.
> >
> >Any help much appreciated.
> >
> >Rob Tice
> >
> >
> >
> >
Re: choice or sequence min/max occurs [message #593082 is a reply to message #55964] Mon, 06 December 2004 23:08 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 26137
Registered: July 2009
Senior Member
Rob,

An XSDModelGroup is reached from an XSDParticle, and that is what holds
the min/max occurs. The same model group could be reached by multiple
particles, as for a model group in model group definition that has a
different min/max occurs at each point of reference. So don't expect to
be able to work back from an element declaration or model group to the
particle that references it, since there isn't a unique answer (although
often it will be just the container).


Rob Tice wrote:

>Apologies if this is a trivial problem I just cant see how to get the info.
>
>I am traversing a schema and I have got to the point where I have my XSD
>model group. I am using the model group getContents() to traverse the
>elements all working okay schema analysis working. However I also need to
>know what each choice or sequence has as it min/max occurs so I can properly
>understand the relative min/max occurs of the contained elements.
>
>Any help much appreciated.
>
>Rob Tice
>
>
>
>
Re: choice or sequence min/max occurs [message #593113 is a reply to message #56017] Tue, 07 December 2004 00:50 Go to previous message
Eclipse User
Originally posted by: rob.tice.k-int.com

Thanks Ed

Problem solved


"Ed Merks" <merks@ca.ibm.com> wrote in message
news:cp2opq$osv$1@www.eclipse.org...
> Rob,
>
> An XSDModelGroup is reached from an XSDParticle, and that is what holds
> the min/max occurs. The same model group could be reached by multiple
> particles, as for a model group in model group definition that has a
> different min/max occurs at each point of reference. So don't expect to
> be able to work back from an element declaration or model group to the
> particle that references it, since there isn't a unique answer (although
> often it will be just the container).
>
>
> Rob Tice wrote:
>
> >Apologies if this is a trivial problem I just cant see how to get the
info.
> >
> >I am traversing a schema and I have got to the point where I have my XSD
> >model group. I am using the model group getContents() to traverse the
> >elements all working okay schema analysis working. However I also need to
> >know what each choice or sequence has as it min/max occurs so I can
properly
> >understand the relative min/max occurs of the contained elements.
> >
> >Any help much appreciated.
> >
> >Rob Tice
> >
> >
> >
> >
Previous Topic:XML <-> ASN.1 : Developer response?
Next Topic:min/max Occurs
Goto Forum:
  


Current Time: Thu Oct 23 22:12:35 GMT 2014

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

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