Then create the following Client implementation:
package com.jadobo.ws; import java.net.URL; import javax.xml.namespace.QName; import javax.xml.ws.Service; public class TestMain { private static final QName SERVICE_NAME = new QName("http://ws.jadobo.com/", "HelloWorldService"); public static void main(String args[]) throws Exception { URL wsdl = new URL("http://localhost:9000/helloWorld?wsdl"); Service service = Service.create(wsdl, SERVICE_NAME); HelloWorld hw = service.getPort(HelloWorld.class); System.out.println(hw.sayHi("World")); } }
Sample console output after Client execution:
INFO: Dynamically creating request wrapper Class com.jadobo.ws.jaxws.SayHi INFO: Dynamically creating response wrapper bean Class com.jadobo.ws.jaxws.SayHiResponse Hello: World
You guys out there are performing a great job.
ReplyDeletetulsa web design
Java development more secured and used in to prepared high performance software. ERP software development especially developed in java, because it has had fewer chances of errors and bugs.
ReplyDelete