001: /**
002: * HelloPortComponentSoapBindingStub.java
003: *
004: * This file was auto-generated from WSDL
005: * by the Apache Axis WSDL2Java emitter.
006: */package org.objectweb.jonas.jtests.hello;
007:
008: public class HelloPortComponentSoapBindingStub extends
009: org.apache.axis.client.Stub implements
010: org.objectweb.jonas.jtests.hello.HelloWs {
011: private java.util.Vector cachedSerClasses = new java.util.Vector();
012: private java.util.Vector cachedSerQNames = new java.util.Vector();
013: private java.util.Vector cachedSerFactories = new java.util.Vector();
014: private java.util.Vector cachedDeserFactories = new java.util.Vector();
015:
016: static org.apache.axis.description.OperationDesc[] _operations;
017:
018: static {
019: _operations = new org.apache.axis.description.OperationDesc[1];
020: org.apache.axis.description.OperationDesc oper;
021: oper = new org.apache.axis.description.OperationDesc();
022: oper.setName("sayHello");
023: oper.addParameter(new javax.xml.namespace.QName("", "in0"),
024: new javax.xml.namespace.QName(
025: "http://schemas.xmlsoap.org/soap/encoding/",
026: "string"), java.lang.String.class,
027: org.apache.axis.description.ParameterDesc.IN, false,
028: false);
029: oper.setReturnType(new javax.xml.namespace.QName(
030: "http://schemas.xmlsoap.org/soap/encoding/", "string"));
031: oper.setReturnClass(java.lang.String.class);
032: oper
033: .setReturnQName(new javax.xml.namespace.QName("",
034: "return"));
035: oper.setStyle(org.apache.axis.constants.Style.RPC);
036: oper.setUse(org.apache.axis.constants.Use.ENCODED);
037: _operations[0] = oper;
038:
039: }
040:
041: public HelloPortComponentSoapBindingStub()
042: throws org.apache.axis.AxisFault {
043: this (null);
044: }
045:
046: public HelloPortComponentSoapBindingStub(java.net.URL endpointURL,
047: javax.xml.rpc.Service service)
048: throws org.apache.axis.AxisFault {
049: this (service);
050: super .cachedEndpoint = endpointURL;
051: }
052:
053: public HelloPortComponentSoapBindingStub(
054: javax.xml.rpc.Service service)
055: throws org.apache.axis.AxisFault {
056: if (service == null) {
057: super .service = new org.apache.axis.client.Service();
058: } else {
059: super .service = service;
060: }
061: }
062:
063: private org.apache.axis.client.Call createCall()
064: throws java.rmi.RemoteException {
065: try {
066: org.apache.axis.client.Call _call = (org.apache.axis.client.Call) super .service
067: .createCall();
068: if (super .maintainSessionSet) {
069: _call.setMaintainSession(super .maintainSession);
070: }
071: if (super .cachedUsername != null) {
072: _call.setUsername(super .cachedUsername);
073: }
074: if (super .cachedPassword != null) {
075: _call.setPassword(super .cachedPassword);
076: }
077: if (super .cachedEndpoint != null) {
078: _call.setTargetEndpointAddress(super .cachedEndpoint);
079: }
080: if (super .cachedTimeout != null) {
081: _call.setTimeout(super .cachedTimeout);
082: }
083: if (super .cachedPortName != null) {
084: _call.setPortName(super .cachedPortName);
085: }
086: java.util.Enumeration keys = super .cachedProperties.keys();
087: while (keys.hasMoreElements()) {
088: java.lang.String key = (java.lang.String) keys
089: .nextElement();
090: _call.setProperty(key, super .cachedProperties.get(key));
091: }
092: return _call;
093: } catch (java.lang.Throwable t) {
094: throw new org.apache.axis.AxisFault(
095: "Failure trying to get the Call object", t);
096: }
097: }
098:
099: public java.lang.String sayHello(java.lang.String in0)
100: throws java.rmi.RemoteException {
101: if (super .cachedEndpoint == null) {
102: throw new org.apache.axis.NoEndPointException();
103: }
104: org.apache.axis.client.Call _call = createCall();
105: _call.setOperation(_operations[0]);
106: _call.setUseSOAPAction(true);
107: _call.setSOAPActionURI("");
108: _call
109: .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
110: _call.setOperationName(new javax.xml.namespace.QName(
111: "http://hello.simple", "sayHello"));
112:
113: setRequestHeaders(_call);
114: setAttachments(_call);
115: java.lang.Object _resp = _call
116: .invoke(new java.lang.Object[] { in0 });
117:
118: if (_resp instanceof java.rmi.RemoteException) {
119: throw (java.rmi.RemoteException) _resp;
120: } else {
121: extractAttachments(_call);
122: try {
123: return (java.lang.String) _resp;
124: } catch (java.lang.Exception _exception) {
125: return (java.lang.String) org.apache.axis.utils.JavaUtils
126: .convert(_resp, java.lang.String.class);
127: }
128: }
129: }
130:
131: }
|