• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Please Help to write client for Webservice

 
chinna sankar
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I need to sent a file as a SOAP attachment (Multi part Message)in Webservices. I am using axis
for generation WSDL and Wsdd Files

Can u help me in how to write a client for below


*****My Interface Defination is

package DhPack;

public interface AttachmentTip extends java.rmi.Remote {
public void sendOctet(javax.activation.DataHandler in0) throws java.rmi.RemoteException;
}



*****WSDL File is
<?xml version="1.0" encoding="UTF-8"?>
<wsdl efinitions targetNamespace="urn:AttachmentTip" xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="urn:AttachmentTip" xmlns:intf="urn:AttachmentTip" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<!--WSDL created by Apache Axis version: 1.3
Built on Oct 05, 2005 (05:23:37 EDT)-->

<wsdl:message name="sendOctetResponse">

</wsdl:message>

<wsdl:message name="sendOctetRequest">

<wsdl art name="in0" type="apachesoap ataHandler"/>

</wsdl:message>

<wsdl ortType name="AttachmentTip">

<wsdl peration name="sendOctet" parameterOrder="in0">

<wsdl:input message="impl:sendOctetRequest" name="sendOctetRequest"/>

<wsdl utput message="impl:sendOctetResponse" name="sendOctetResponse"/>

</wsdl peration>

</wsdl ortType>

<wsdl:binding name="AttachmentTipSoapBinding" type="impl:AttachmentTip">

<wsdlsoap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>

<wsdl peration name="sendOctet">

<wsdlsoap peration soapAction=""/>

<wsdl:input name="sendOctetRequest">

<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:AttachmentTip" use="encoded"/>

</wsdl:input>

<wsdl utput name="sendOctetResponse">

<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:AttachmentTip" use="encoded"/>

</wsdl utput>

</wsdl peration>

</wsdl:binding>

<wsdl:service name="AttachmentTipService">

<wsdl ort binding="impl:AttachmentTipSoapBinding" name="AttachmentTip">

<wsdlsoap:address location="http://localhost:8080/axis/services/AttachmentTip"/>

</wsdl ort>

</wsdl:service>

</wsdl efinitions>

*****WSDL File is End


****************and My WSDD file is

<deployment
xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">

<!-- Services from AttachmentTipService WSDL service -->

<service name="AttachmentTip" provider="java:RPC" style="rpc" use="encoded">
<parameter name="wsdlTargetNamespace" value="urn:AttachmentTip"/>
<parameter name="wsdlServiceElement" value="AttachmentTipService"/>
<parameter name="wsdlServicePort" value="AttachmentTip"/>
<parameter name="className" value="DhPack.AttachmentTipSoapBindingSkeleton"/>
<parameter name="wsdlPortType" value="AttachmentTip"/>
<parameter name="typeMappingVersion" value="1.2"/>
<parameter name="allowedMethods" value="*"/>

</service>
</deployment>
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Reading this article may provide you with some help.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic