Given a WSDL file, create a simple Java client

Can anyone provide me some sample code for this? I have a wsdl file and I want to create a client that will call a service from this wsdl file.
Working code with some explanation will be really useful.

I am using JDK 1.4.

+5
source share
5 answers

Main parameters:

Both links contain code examples. Some searches on the Internet will help you even further. There are also options for creating dynamic SOAP clients, but the ones generated from them are the easiest.

+10
source

WSDL2Java. :

$ java org.apache.axis.wsdl.WSDL2Java foo.wsdl
+3

NetBeans can generate a lot of code for you: File → New File ... → Web Servers → Web Service Client

+2
source

I have seen Apache Axis do this automatically. You can try to find out a little about it.

0
source

Eclipse has the ability to generate a java client.
Just right-click on the WSDL file.
Creating a Web Service Client
This is all. You are calling the client to invoke the SOAP service

0
source

All Articles