W3C home > Mailing lists > Public > xml-dist-app@w3.org > July 2002

Re: What is the difference between a "struct" and an "array" in the e dge case?

From: Jacek Kopecky <jacek@systinet.com>
Date: Tue, 2 Jul 2002 15:36:32 +0200 (CEST)
To: Marc Hadley <marc.hadley@sun.com>
cc: Kevin Johnsrude <kevinj@roguewave.com>, <xml-dist-app@w3.org>
Message-ID: <Pine.LNX.4.44.0207021533130.32597-100000@mail.idoox.com>

 Marc,
 the way I was reading that text was that "if, when accessing the
compound type, the edges are accessed by their label only, the
element qname is the label. If they are accessed by position, the
label is ignored and so is the element qname then." Basically,
"distinguishing between accessors" I understand as "what I use to 
get one of them", not "how are they different".
 Best regards,

                   Jacek Kopecky

                   Senior Architect, Systinet Corporation
                   http://www.systinet.com/



On Tue, 2 Jul 2002, Marc Hadley wrote:

 > Jacek Kopecky wrote:
 > >  Marc, Kevin, 
 > >  I believe that since in array the names are irrelevant, we must 
 > > not assume that they are the same. The name may be used for type 
 > > matching (if using some schema validation as suggested in 
 > > http://www.w3.org/TR/soap12-part2/#encschema ) or it may be 
 > > generated or (usually) it can be the same (like 'item' or 
 > > something) but the latter is just one of the options.
 >  >
 > Hmmm, thats not my reading of it. The rules in [1] are:
 > 
 > "1. For a graph edge which is distinguished by label ("struct" or 
 > "generic"), the namespace name and local name properties of the element 
 > information item together determine the value of the edge label.
 >   2. For a graph edge which is distinguished by position ("array" or 
 > "generic"):
 >      * The ordinal position of the graph edge corresponds to the 
 > position of the element information item relative to its siblings
 >      * If outbound edges are distinguished only by position ("array") 
 > then the local name and namespace name properties of the element 
 > information item are not significant."
 > 
 > If the names of the child elements are not the same then the outbound 
 > edges are NOT distinguished only by position (see 2, bullet 2 above) and 
 > hence you have a generic rather than an array.
 > 
 > I agree that the actual names of the array elements are not significant 
 > (although, as Jacek notes, they can be used for type matching) but they 
 > should all be the same.
 > 
 > Marc.
 > 
 > [1] http://www.w3.org/TR/2002/WD-soap12-part2-20020626/#complexenc
 > 
 > 
 > > 
 > > 
 > > 
 > > On Tue, 2 Jul 2002, Marc Hadley wrote:
 > > 
 > >  >  > Kevin Johnsrude wrote:
 > >  > > In SOAP 1.2, 3.1.2 "Encoding compound values" [1], is there any way to
 > >  > > distinguish between a "struct" and an "array" that has neither an "itemType"
 > >  > > nor an "arraySize" attribute?  Note that this appears to be permitted per
 > >  > > item 3.
 > >  > >  > IIRC, an array's child elements all have the same name. A struct's child 
 > >  > elements all have different names. A generics child elements can be a 
 > >  > mixture of the two.
 > >  >  > So, for a struct or array with only one child element then its difficult 
 > >  > to tell the difference without the attributes.
 > >  >  > Regards,
 > >  > Marc.
 > >  >  > > [1] http://www.w3.org/TR/2002/WD-soap12-part2-20020626/#complexenc
 > >  > >  >  >  >  > 
 > 
 > 
 > 
 > 
Received on Tuesday, 2 July 2002 09:36:34 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:59:10 GMT