• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

default value for style attribute in soap:binding

 
Sundar Murthi
Ranch Hand
Posts: 209
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have found this question in wizlab trial.

What is the default value of the "style" attribute of the <soap:binding> element in case explicitly its not specified?

a) remote
b) document
c) rpc
d) literal
e) encoded

I was more confused to answer to this question because in wsdl we always specify style attribute.


In whizlab answer they said its b) document.

I hope its wrong. because according to soap schema style is optional but there is no default value. Following is the declaration from soap xsd.

<xs:complexType name="tBinding">
- <xs:complexContent>
- <xs:extension base="wsdl:tExtensibilityElement">
<xs:attribute name="transport" type="xs:anyURI" use="required" />
<xs:attribute name="style" type="soap:tStyleChoice" use="optional" />
</xs:extension>
</xs:complexContent>
</xs:complexType>


And according to wsdl schema binding style is must required attribute.

Please give your thoughts if I am wrong.

Is it a buggy question or not?
 
Remko Strating
Ranch Hand
Posts: 893
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is from Web Services Description Language (WSDL). The url linking isn't working, but you can find in http://www.w3.org/TR/wsdl#_soap peration



The style attribute indicates whether the operation is RPC-oriented (messages containing parameters and return values) or document-oriented (message containing document(s)). This information may be used to select an appropriate programming model. The value of this attribute also affects the way in which the Body of the SOAP message is constructed, as explained in Section 3.5 below. If the attribute is not specified, it defaults to the value specified in the soap:binding element. If the soap:binding element does not specify a style, it is assumed to be "document".


I hope this will clarify your doubt.

[ July 02, 2008: Message edited by: Remko Strating ]

[ July 02, 2008: Message edited by: Remko Strating ]
[ July 02, 2008: Message edited by: Remko Strating ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic