Q: How do I get headers to show up in the WSDL generated for my service?

A: With the inHeader and outHeader attributes, operation parameters can be defined as header elements. Axis will define these parameters as header in the generated WSDL for the operation. Note that these are parameters to the Java function that is part of the service.


 <operation name="addMovie" 
   <parameter name="title" type="xsd:string" inHeader="true"/> 
   <parameter name="pricePerDay" type="xsd:double" outHeader="true"/> 

This would be the WSDD operation definition for a Java function with a signature of addMovie(String title, DoubleHolder pricePerDay)

A2: Another option is to use the Handler.generateWSDL() hook.

FrontPage/Axis/WSDLJavaHeaderWSDL (last edited 2009-09-20 22:47:37 by localhost)