You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Ge...@nokia.com on 2002/08/16 11:01:54 UTC

attachements and headers

Hi,

 I have the foolowing problem: I'm using WSDL2Java to generate
client code for a SOAP application. I would like to send attachments
and custom SOAP headers, but without touching the generated code.
Client code generation and usage is automatized so there is no way for me 
to alter the generated code before using it. I know attechments can
be added to the Call object, but the Call objects are not available to
me any more, since they are created at every method call. 
 Is there any way currently that I can solve this problem ? 

 If there is no way, please read forward, and see what I figured out.
Looking at the Call source is that maybe I can
solve this by adding attachements and headers (or other info) to the
client stub using the generated API, as properties. These will
finally be put into the MessageContext by the Call object. This way
I might write a client-side handler that will extract those properties
and convert them into proper attachments, inserting them into the
Message object. 

 What do you think about this ? Will it work ? 

  Thanx in advance for your answers, Geza