The specs don't say whether attributes are permitted in "grandchild"
elements (children of the parameter elements). For maximum interoperability,
I would say that you should *not* use attributes with wrapped style at any
level. But, as long you have a custom serializer that maps the object fields
to the XML attributes, then it should work. But any time you require custom
serializers, you're making interoperability all that much harder, though.

Anne

-----Original Message-----
From: Jim Murphy [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, April 27, 2004 3:29 PM
To: [EMAIL PROTECTED]
Subject: Re: Have doubts about Doc/Lit with axis

Anne Thomas Manes wrote:

> For the most part, I concur with Jim. If you want to create an RMI-style
> programming interface, always use wrapped/literal. On the other hand, if
you
> want to send a predefined schema (such as a standard schema defined by
your
> favorite vertical industry group), you may need to use Document/Literal --
> particularly if the schema contains attributes. Wrapped/Literal simulates
> the RPC style, and it doesn't permit attributes. 

Just to *finally* get this clear in my own mind.  I've always assumed 
that Wrapped disallowed attributes at the "parameters" level.  So if I 
had an operation that took a complexType as an argument the type itself 
could have attribute content as long as the wrapper itself doesn't.  Is 
this wrong?


void foo(SomeType t)

Might look like this on the wire:

<Envelope>
   <Body>
      <foo> <!-- No attribute allowed - for sure -->
         <t> <!-- No attribute allowed - don't know why not? -->
           <a c="d" /> <!-- Attribute allowed - aren't they? -->
           <b />
         </t>
      </foo>
   </Body>
</Envelope>


Jim Murphy
Mindreef, Inc.


Reply via email to