Select all cutandpaste
[jalview.git] / src / ext / vamsas / JpredSoapBindingStub.java
1 /**
2  * JpredSoapBindingStub.java
3  *
4  * This file was auto-generated from WSDL
5  * by the Apache Axis 1.2RC2 Nov 16, 2004 (12:19:44 EST) WSDL2Java emitter.
6  */
7
8 package ext.vamsas;
9
10 public class JpredSoapBindingStub extends org.apache.axis.client.Stub implements ext.vamsas.Jpred {
11     private java.util.Vector cachedSerClasses = new java.util.Vector();
12     private java.util.Vector cachedSerQNames = new java.util.Vector();
13     private java.util.Vector cachedSerFactories = new java.util.Vector();
14     private java.util.Vector cachedDeserFactories = new java.util.Vector();
15
16     static org.apache.axis.description.OperationDesc [] _operations;
17
18     static {
19         _operations = new org.apache.axis.description.OperationDesc[4];
20         _initOperationDesc1();
21     }
22
23     private static void _initOperationDesc1(){
24         org.apache.axis.description.OperationDesc oper;
25         oper = new org.apache.axis.description.OperationDesc();
26         oper.setName("predict");
27         oper.addParameter(new javax.xml.namespace.QName("", "seq"), new javax.xml.namespace.QName("simple.objects.vamsas", "Sequence"), vamsas.objects.simple.Sequence.class, org.apache.axis.description.ParameterDesc.IN, false, false);
28         oper.setReturnType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
29         oper.setReturnClass(java.lang.String.class);
30         oper.setReturnQName(new javax.xml.namespace.QName("", "predictReturn"));
31         oper.setStyle(org.apache.axis.constants.Style.RPC);
32         oper.setUse(org.apache.axis.constants.Use.ENCODED);
33         _operations[0] = oper;
34
35         oper = new org.apache.axis.description.OperationDesc();
36         oper.setName("predictOnMsa");
37         oper.addParameter(new javax.xml.namespace.QName("", "msf"), new javax.xml.namespace.QName("http://simple.objects.vamsas", "Msfalignment"), vamsas.objects.simple.Msfalignment.class, org.apache.axis.description.ParameterDesc.IN, false, false);
38         oper.setReturnType(new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"));
39         oper.setReturnClass(java.lang.String.class);
40         oper.setReturnQName(new javax.xml.namespace.QName("", "predictOnMsaReturn"));
41         oper.setStyle(org.apache.axis.constants.Style.RPC);
42         oper.setUse(org.apache.axis.constants.Use.ENCODED);
43         _operations[1] = oper;
44
45         oper = new org.apache.axis.description.OperationDesc();
46         oper.setName("getpredict");
47         oper.addParameter(new javax.xml.namespace.QName("", "job_id"), new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"), java.lang.String.class, org.apache.axis.description.ParameterDesc.IN, false, false);
48         oper.setReturnType(new javax.xml.namespace.QName("http://simple.objects.vamsas", "Secstructpred"));
49         oper.setReturnClass(vamsas.objects.simple.Secstructpred.class);
50         oper.setReturnQName(new javax.xml.namespace.QName("", "getpredictReturn"));
51         oper.setStyle(org.apache.axis.constants.Style.RPC);
52         oper.setUse(org.apache.axis.constants.Use.ENCODED);
53         _operations[2] = oper;
54
55         oper = new org.apache.axis.description.OperationDesc();
56         oper.setName("getresult");
57         oper.addParameter(new javax.xml.namespace.QName("", "job_id"), new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "string"), java.lang.String.class, org.apache.axis.description.ParameterDesc.IN, false, false);
58         oper.setReturnType(new javax.xml.namespace.QName("http://simple.objects.vamsas", "JpredResult"));
59         oper.setReturnClass(vamsas.objects.simple.JpredResult.class);
60         oper.setReturnQName(new javax.xml.namespace.QName("", "getresultReturn"));
61         oper.setStyle(org.apache.axis.constants.Style.RPC);
62         oper.setUse(org.apache.axis.constants.Use.ENCODED);
63         _operations[3] = oper;
64
65     }
66
67     public JpredSoapBindingStub() throws org.apache.axis.AxisFault {
68          this(null);
69     }
70
71     public JpredSoapBindingStub(java.net.URL endpointURL, javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
72          this(service);
73          super.cachedEndpoint = endpointURL;
74     }
75
76     public JpredSoapBindingStub(javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
77         if (service == null) {
78             super.service = new org.apache.axis.client.Service();
79         } else {
80             super.service = service;
81         }
82             java.lang.Class cls;
83             javax.xml.namespace.QName qName;
84             java.lang.Class beansf = org.apache.axis.encoding.ser.BeanSerializerFactory.class;
85             java.lang.Class beandf = org.apache.axis.encoding.ser.BeanDeserializerFactory.class;
86             /*java.lang.Class enumsf = org.apache.axis.encoding.ser.EnumSerializerFactory.class;
87             java.lang.Class enumdf = org.apache.axis.encoding.ser.EnumDeserializerFactory.class;
88             java.lang.Class arraysf = org.apache.axis.encoding.ser.ArraySerializerFactory.class;
89             java.lang.Class arraydf = org.apache.axis.encoding.ser.ArrayDeserializerFactory.class;
90             java.lang.Class simplesf = org.apache.axis.encoding.ser.SimpleSerializerFactory.class;
91             java.lang.Class simpledf = org.apache.axis.encoding.ser.SimpleDeserializerFactory.class;
92             java.lang.Class simplelistsf = org.apache.axis.encoding.ser.SimpleListSerializerFactory.class;
93             java.lang.Class simplelistdf = org.apache.axis.encoding.ser.SimpleListDeserializerFactory.class;*/
94             qName = new javax.xml.namespace.QName("http://simple.objects.vamsas", "JpredResult");
95             cachedSerQNames.add(qName);
96             cls = vamsas.objects.simple.JpredResult.class;
97             cachedSerClasses.add(cls);
98             cachedSerFactories.add(beansf);
99             cachedDeserFactories.add(beandf);
100
101             qName = new javax.xml.namespace.QName("simple.objects.vamsas", "Result");
102             cachedSerQNames.add(qName);
103             cls = vamsas.objects.simple.Result.class;
104             cachedSerClasses.add(cls);
105             cachedSerFactories.add(beansf);
106             cachedDeserFactories.add(beandf);
107
108             qName = new javax.xml.namespace.QName("http://simple.objects.vamsas", "Secstructpred");
109             cachedSerQNames.add(qName);
110             cls = vamsas.objects.simple.Secstructpred.class;
111             cachedSerClasses.add(cls);
112             cachedSerFactories.add(beansf);
113             cachedDeserFactories.add(beandf);
114
115             qName = new javax.xml.namespace.QName("http://simple.objects.vamsas", "Msfalignment");
116             cachedSerQNames.add(qName);
117             cls = vamsas.objects.simple.Msfalignment.class;
118             cachedSerClasses.add(cls);
119             cachedSerFactories.add(beansf);
120             cachedDeserFactories.add(beandf);
121
122             qName = new javax.xml.namespace.QName("simple.objects.vamsas", "Sequence");
123             cachedSerQNames.add(qName);
124             cls = vamsas.objects.simple.Sequence.class;
125             cachedSerClasses.add(cls);
126             cachedSerFactories.add(beansf);
127             cachedDeserFactories.add(beandf);
128
129     }
130
131     protected org.apache.axis.client.Call createCall() throws java.rmi.RemoteException {
132         try {
133             org.apache.axis.client.Call _call =
134                     (org.apache.axis.client.Call) super.service.createCall();
135             if (super.maintainSessionSet) {
136                 _call.setMaintainSession(super.maintainSession);
137             }
138             if (super.cachedUsername != null) {
139                 _call.setUsername(super.cachedUsername);
140             }
141             if (super.cachedPassword != null) {
142                 _call.setPassword(super.cachedPassword);
143             }
144             if (super.cachedEndpoint != null) {
145                 _call.setTargetEndpointAddress(super.cachedEndpoint);
146             }
147             if (super.cachedTimeout != null) {
148                 _call.setTimeout(super.cachedTimeout);
149             }
150             if (super.cachedPortName != null) {
151                 _call.setPortName(super.cachedPortName);
152             }
153             java.util.Enumeration keys = super.cachedProperties.keys();
154             while (keys.hasMoreElements()) {
155                 java.lang.String key = (java.lang.String) keys.nextElement();
156                 _call.setProperty(key, super.cachedProperties.get(key));
157             }
158             // All the type mapping information is registered
159             // when the first call is made.
160             // The type mapping information is actually registered in
161             // the TypeMappingRegistry of the service, which
162             // is the reason why registration is only needed for the first call.
163             synchronized (this) {
164                 if (firstCall()) {
165                     // must set encoding style before registering serializers
166                     _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
167                     _call.setEncodingStyle(org.apache.axis.Constants.URI_SOAP11_ENC);
168                     for (int i = 0; i < cachedSerFactories.size(); ++i) {
169                         java.lang.Class cls = (java.lang.Class) cachedSerClasses.get(i);
170                         javax.xml.namespace.QName qName =
171                                 (javax.xml.namespace.QName) cachedSerQNames.get(i);
172                         java.lang.Class sf = (java.lang.Class)
173                                  cachedSerFactories.get(i);
174                         java.lang.Class df = (java.lang.Class)
175                                  cachedDeserFactories.get(i);
176                         _call.registerTypeMapping(cls, qName, sf, df, false);
177                     }
178                 }
179             }
180             return _call;
181         }
182         catch (java.lang.Throwable _t) {
183             throw new org.apache.axis.AxisFault("Failure trying to get the Call object", _t);
184         }
185     }
186
187     public java.lang.String predict(vamsas.objects.simple.Sequence seq) throws java.rmi.RemoteException {
188         if (super.cachedEndpoint == null) {
189             throw new org.apache.axis.NoEndPointException();
190         }
191         org.apache.axis.client.Call _call = createCall();
192         _call.setOperation(_operations[0]);
193         _call.setUseSOAPAction(true);
194         _call.setSOAPActionURI("");
195         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
196         _call.setOperationName(new javax.xml.namespace.QName("vamsas", "predict"));
197
198         setRequestHeaders(_call);
199         setAttachments(_call);
200         java.lang.Object _resp = _call.invoke(new java.lang.Object[] {seq});
201
202         if (_resp instanceof java.rmi.RemoteException) {
203             throw (java.rmi.RemoteException)_resp;
204         }
205         else {
206             extractAttachments(_call);
207             try {
208                 return (java.lang.String) _resp;
209             } catch (java.lang.Exception _exception) {
210                 return (java.lang.String) org.apache.axis.utils.JavaUtils.convert(_resp, java.lang.String.class);
211             }
212         }
213     }
214
215     public java.lang.String predictOnMsa(vamsas.objects.simple.Msfalignment msf) throws java.rmi.RemoteException {
216         if (super.cachedEndpoint == null) {
217             throw new org.apache.axis.NoEndPointException();
218         }
219         org.apache.axis.client.Call _call = createCall();
220         _call.setOperation(_operations[1]);
221         _call.setUseSOAPAction(true);
222         _call.setSOAPActionURI("");
223         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
224         _call.setOperationName(new javax.xml.namespace.QName("vamsas", "predictOnMsa"));
225
226         setRequestHeaders(_call);
227         setAttachments(_call);
228         java.lang.Object _resp = _call.invoke(new java.lang.Object[] {msf});
229
230         if (_resp instanceof java.rmi.RemoteException) {
231             throw (java.rmi.RemoteException)_resp;
232         }
233         else {
234             extractAttachments(_call);
235             try {
236                 return (java.lang.String) _resp;
237             } catch (java.lang.Exception _exception) {
238                 return (java.lang.String) org.apache.axis.utils.JavaUtils.convert(_resp, java.lang.String.class);
239             }
240         }
241     }
242
243     public vamsas.objects.simple.Secstructpred getpredict(java.lang.String job_id) throws java.rmi.RemoteException {
244         if (super.cachedEndpoint == null) {
245             throw new org.apache.axis.NoEndPointException();
246         }
247         org.apache.axis.client.Call _call = createCall();
248         _call.setOperation(_operations[2]);
249         _call.setUseSOAPAction(true);
250         _call.setSOAPActionURI("");
251         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
252         _call.setOperationName(new javax.xml.namespace.QName("vamsas", "getpredict"));
253
254         setRequestHeaders(_call);
255         setAttachments(_call);
256         java.lang.Object _resp = _call.invoke(new java.lang.Object[] {job_id});
257
258         if (_resp instanceof java.rmi.RemoteException) {
259             throw (java.rmi.RemoteException)_resp;
260         }
261         else {
262             extractAttachments(_call);
263             try {
264                 return (vamsas.objects.simple.Secstructpred) _resp;
265             } catch (java.lang.Exception _exception) {
266                 return (vamsas.objects.simple.Secstructpred) org.apache.axis.utils.JavaUtils.convert(_resp, vamsas.objects.simple.Secstructpred.class);
267             }
268         }
269     }
270
271     public vamsas.objects.simple.JpredResult getresult(java.lang.String job_id) throws java.rmi.RemoteException {
272         if (super.cachedEndpoint == null) {
273             throw new org.apache.axis.NoEndPointException();
274         }
275         org.apache.axis.client.Call _call = createCall();
276         _call.setOperation(_operations[3]);
277         _call.setUseSOAPAction(true);
278         _call.setSOAPActionURI("");
279         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
280         _call.setOperationName(new javax.xml.namespace.QName("vamsas", "getresult"));
281
282         setRequestHeaders(_call);
283         setAttachments(_call);
284         java.lang.Object _resp = _call.invoke(new java.lang.Object[] {job_id});
285
286         if (_resp instanceof java.rmi.RemoteException) {
287             throw (java.rmi.RemoteException)_resp;
288         }
289         else {
290             extractAttachments(_call);
291             try {
292                 return (vamsas.objects.simple.JpredResult) _resp;
293             } catch (java.lang.Exception _exception) {
294                 return (vamsas.objects.simple.JpredResult) org.apache.axis.utils.JavaUtils.convert(_resp, vamsas.objects.simple.JpredResult.class);
295             }
296         }
297     }
298
299 }