|
Re: XSDSchema serialization [message #44807 is a reply to message #44770] |
Tue, 18 May 2004 15:40 |
Eclipse User |
|
|
|
Originally posted by: merks.ca.ibm.com
Rodolfo,
Doing xsdSchema.eResource().save(System.out, null) should serialize your
instance.
Rodolfo Botto wrote:
> Is there a chance to serialize an XSDSchema ? I having performance trouble
> with XSDSchema instanciation from DOM, and in my case, can be avoided if I
> can serialize and XSDSchema.
|
|
|
SubstitutionGroups Help! [message #44889 is a reply to message #44807] |
Thu, 20 May 2004 21:05 |
Eclipse User |
|
|
|
Originally posted by: jmurphy.mindreef.com
Hi everyone.
I'm trying to understand how to use XSD's SubstitutionGroups support. I
understand the XML/Schema construct at a practical level but I'm unclear
about the APIs:
1. ElementDecl.getSubstitutionGroupExclusions
2. ElementDecl.getSubstitutionGroup
3. ElementDecl.getSubstitutionGroupAffiliation
That I want to do is compile a list of substitutions given an abstract
element declaration. I expected to be able to call
elemDecl.getSubstitutionGroup and ave that return all of the
elementDecls that can substitute. But only the element itself is
included. An I out to lunch? Alsi what is an affiliation and an exculsion?
Thanks
Jim
Mindreef, Inc.
|
|
|
Re: SubstitutionGroups Help! [message #44906 is a reply to message #44889] |
Thu, 20 May 2004 23:04 |
Eclipse User |
|
|
|
Originally posted by: merks.ca.ibm.com
Jim,
I'm not sure whether you have lunch in or out. ;-)
Each of these things have Javadoc that point at where the concept is defined in
the spec, so there's no point in repeating that information. I know the spec is
not much fun to read, but it's very precise. The basic idea is that
getSubstitutionGroupAffiliation is a concrete relation that set's up the
substitution group by saying "This element belongs to that element's group".
The getSubstitutionGroupExclusions defines limitations on what kinds of elements
can be in the element's group. And the getSubstitutionGroup returns all the
elements that are directly or indirectly in the group by virtue of the
affiliations.
Were you trying this out with any particular examples in mind?
Jim Murphy wrote:
> Hi everyone.
>
> I'm trying to understand how to use XSD's SubstitutionGroups support. I
> understand the XML/Schema construct at a practical level but I'm unclear
> about the APIs:
>
> 1. ElementDecl.getSubstitutionGroupExclusions
> 2. ElementDecl.getSubstitutionGroup
> 3. ElementDecl.getSubstitutionGroupAffiliation
>
> That I want to do is compile a list of substitutions given an abstract
> element declaration. I expected to be able to call
> elemDecl.getSubstitutionGroup and ave that return all of the
> elementDecls that can substitute. But only the element itself is
> included. An I out to lunch? Alsi what is an affiliation and an exculsion?
>
> Thanks
>
> Jim
> Mindreef, Inc.
|
|
|
Re: SubstitutionGroups Help! [message #45191 is a reply to message #44906] |
Fri, 21 May 2004 17:07 |
Eclipse User |
|
|
|
Originally posted by: user.domain.invalid
Lol - sorry bout that. Kind of lost it yesterday. :)
Thanks for the descriptions - you're spot on. I can *read* the spec but
that doesn't mean I can understand it. If I understand you right this
means the getSubstitutioGroup returns the set of elements that can
substitute for and element while the getSubsitutionGroupAffiliations is
a "back pointer" to the element where this element can substitute.
Actually it turns out the problem I was tracking down was the result of
a bad schema - but pretty understandable.
The author setup a pretty simple substitutionGroup based ona global
element declaration called: fred of type fredType. But, he went on to
attempt to use "fred" by creating a sequence of local elements named
"fred" of type "fredType". "Clearly" the 2 element decls are unrelated
but...
Jim Murphy
Mindreef, Inc.
Ed Merks wrote:
> Jim,
>
> I'm not sure whether you have lunch in or out. ;-)
>
> Each of these things have Javadoc that point at where the concept is defined in
> the spec, so there's no point in repeating that information. I know the spec is
> not much fun to read, but it's very precise. The basic idea is that
> getSubstitutionGroupAffiliation is a concrete relation that set's up the
> substitution group by saying "This element belongs to that element's group".
> The getSubstitutionGroupExclusions defines limitations on what kinds of elements
> can be in the element's group. And the getSubstitutionGroup returns all the
> elements that are directly or indirectly in the group by virtue of the
> affiliations.
>
> Were you trying this out with any particular examples in mind?
>
>
> Jim Murphy wrote:
>
>
>>Hi everyone.
>>
>>I'm trying to understand how to use XSD's SubstitutionGroups support. I
>>understand the XML/Schema construct at a practical level but I'm unclear
>>about the APIs:
>>
>>1. ElementDecl.getSubstitutionGroupExclusions
>>2. ElementDecl.getSubstitutionGroup
>>3. ElementDecl.getSubstitutionGroupAffiliation
>>
>>That I want to do is compile a list of substitutions given an abstract
>>element declaration. I expected to be able to call
>>elemDecl.getSubstitutionGroup and ave that return all of the
>>elementDecls that can substitute. But only the element itself is
>>included. An I out to lunch? Alsi what is an affiliation and an exculsion?
>>
>>Thanks
>>
>>Jim
>>Mindreef, Inc.
>
>
|
|
|
Re: XSDSchema serialization [message #587208 is a reply to message #44770] |
Tue, 18 May 2004 15:40 |
Ed Merks Messages: 33264 Registered: July 2009 |
Senior Member |
|
|
Rodolfo,
Doing xsdSchema.eResource().save(System.out, null) should serialize your
instance.
Rodolfo Botto wrote:
> Is there a chance to serialize an XSDSchema ? I having performance trouble
> with XSDSchema instanciation from DOM, and in my case, can be avoided if I
> can serialize and XSDSchema.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
SubstitutionGroups Help! [message #587261 is a reply to message #44807] |
Thu, 20 May 2004 21:05 |
Eclipse User |
|
|
|
Originally posted by: jmurphy.mindreef.com
Hi everyone.
I'm trying to understand how to use XSD's SubstitutionGroups support. I
understand the XML/Schema construct at a practical level but I'm unclear
about the APIs:
1. ElementDecl.getSubstitutionGroupExclusions
2. ElementDecl.getSubstitutionGroup
3. ElementDecl.getSubstitutionGroupAffiliation
That I want to do is compile a list of substitutions given an abstract
element declaration. I expected to be able to call
elemDecl.getSubstitutionGroup and ave that return all of the
elementDecls that can substitute. But only the element itself is
included. An I out to lunch? Alsi what is an affiliation and an exculsion?
Thanks
Jim
Mindreef, Inc.
|
|
|
Re: SubstitutionGroups Help! [message #587280 is a reply to message #44889] |
Thu, 20 May 2004 23:04 |
Ed Merks Messages: 33264 Registered: July 2009 |
Senior Member |
|
|
Jim,
I'm not sure whether you have lunch in or out. ;-)
Each of these things have Javadoc that point at where the concept is defined in
the spec, so there's no point in repeating that information. I know the spec is
not much fun to read, but it's very precise. The basic idea is that
getSubstitutionGroupAffiliation is a concrete relation that set's up the
substitution group by saying "This element belongs to that element's group".
The getSubstitutionGroupExclusions defines limitations on what kinds of elements
can be in the element's group. And the getSubstitutionGroup returns all the
elements that are directly or indirectly in the group by virtue of the
affiliations.
Were you trying this out with any particular examples in mind?
Jim Murphy wrote:
> Hi everyone.
>
> I'm trying to understand how to use XSD's SubstitutionGroups support. I
> understand the XML/Schema construct at a practical level but I'm unclear
> about the APIs:
>
> 1. ElementDecl.getSubstitutionGroupExclusions
> 2. ElementDecl.getSubstitutionGroup
> 3. ElementDecl.getSubstitutionGroupAffiliation
>
> That I want to do is compile a list of substitutions given an abstract
> element declaration. I expected to be able to call
> elemDecl.getSubstitutionGroup and ave that return all of the
> elementDecls that can substitute. But only the element itself is
> included. An I out to lunch? Alsi what is an affiliation and an exculsion?
>
> Thanks
>
> Jim
> Mindreef, Inc.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
|
Powered by
FUDForum. Page generated in 0.03512 seconds