4
import javax.xml.rpc.Service;
5
import javax.xml.rpc.JAXRPCException;
6
import javax.xml.namespace.QName;
7
import javax.xml.rpc.ServiceFactory;
8
import dynamicproxy.HelloSEI;
10
public class HelloDProxyClient {
13
* @param args the command line arguments
15
public static void main(String[] args) {
18
String UrlString = args[0] + "?WSDL";
19
String nameSpaceUri = "urn:Hello/wsdl";
20
String serviceName = "Hello";
21
String portName = "HelloSEIPort";
23
System.out.println("UrlString = " + UrlString);
24
URL helloWsdlUrl = new URL(UrlString);
26
ServiceFactory serviceFactory =
27
ServiceFactory.newInstance();
29
Service helloService =
30
serviceFactory.createService(helloWsdlUrl,
31
new QName(nameSpaceUri, serviceName));
33
dynamicproxy.HelloSEI myProxy =
34
(dynamicproxy.HelloSEI)
36
new QName(nameSpaceUri, portName),
37
dynamicproxy.HelloSEI.class);
39
System.out.println(myProxy.sayHello("Buzz"));
41
} catch (Exception ex) {