Hi I am sending part of my wsdl which describes the datahandler
<complexType name="Image"> <sequence> <element name="dataHandler" nillable="true" type="apachesoap:DataHandler"/> <element name="data" type="xsd:base64Binary"/> <element name="format" type="xsd:int"/> </sequence> </complexType> When I use WSDL2Java tool it creates a java object with three properties. Here is the definition of properties private javax.activation.DataHandler dataHandler; private byte[] data; private int format; So one of the operation in service returns a message which includes the above message (Image object). So when it reaches in client side I get it as a java object. I have verified with TCPMON that in this case the image comes as attachment. Thanks, Subhendu -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, July 16, 2003 10:18 AM To: [EMAIL PROTECTED] Subject: RE: Axis attachment file created in the Temp directory AFAIK, WSDL has no way to specify attachment handling. The language does not provide constructions for that. If your client sends or recieves attachments, you should handle it yourself. Or am I missing something? May we see your WSDL? Can you send some code sample? ============================================= Marcelo Jaccoud Amaral Petrobras - TI - Negócios Eletrônicos mailto:jaccoud [at] petrobras.com.br voice: +55 21 2534-3485 fax: +55 21 2534-1809 ============================================= There are only 10 kinds of people in the world: those who understand binary and those who don't. "Subhendu Kumar mohanty" Para: <[EMAIL PROTECTED]> <[EMAIL PROTECTED] cc: (cco: Marcelo Jaccoud Amaral/RJ/Petrobras) ys.com> Assunto: RE: Axis attachment file created in the Temp directory 2003-07-16 10:26 Favor responder a axis-user hi, I am using the generated client stub classes from the WSDL of the service. My client program is a java based program. So when I call the method on client stub , Axis does all the internal processing . The service returns a datahandler for image and my client program calls the method on stub which returns a Java object. So in my client I do not do the following thing mentioned by you. But when I debug the Axis code I found that when a datahandler comes it does some processing with ManagedmemoryDataSource. Is there a way I can tell Axis not to Dump files. Let me know if this is confusing. Thanks, Subhendu -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, July 15, 2003 12:53 PM To: [EMAIL PROTECTED] Subject: RE: Axis attachment file created in the Temp directory I noted that my Axis client does not dump the attachments to a file unless I use some data handler function that forces it. For example, if I use dh.getName() Axis will dump the contents to a temp file and return its name. If you just use dh.writeTo() to specify where to put the data, Axis will not created the temp file (if it breates the file, I cannot percieve it). If you ask for the file, Axis will grant ownership to you, and it is your responsability to get rid of it (or move it, rename it, whatever). When I just do DataHandler dh = part.getDataHandler(); dh.writeTo(new java.io.FileOutputStream(myDestinationFileName)); no temp is created. Cheers. ============================================= Marcelo Jaccoud Amaral mailto:jaccoud [at] petrobras.com.br voice: +55 21 2534-3485 fax: +55 21 2534-1809 ============================================= There are only 10 kinds of people in the world: those who understand binary and those who don't.