2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.5)
3 * Copyright (C) 2010 J Procter, AM Waterhouse, G Barton, M Clamp, S Searle
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
11 * Jalview is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
19 * Jalview - A Sequence Alignment Editor and Viewer
20 * Copyright (C) 2007 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle
22 * This program is free software; you can redistribute it and/or
23 * modify it under the terms of the GNU General Public License
24 * as published by the Free Software Foundation; either version 2
25 * of the License, or (at your option) any later version.
27 * This program is distributed in the hope that it will be useful,
28 * but WITHOUT ANY WARRANTY; without even the implied warranty of
29 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 * GNU General Public License for more details.
32 * You should have received a copy of the GNU General Public License
33 * along with this program; if not, write to the Free Software
34 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
38 public class MuscleWSSoapBindingStub extends org.apache.axis.client.Stub
39 implements ext.vamsas.MuscleWS
41 static org.apache.axis.description.OperationDesc[] _operations;
45 _operations = new org.apache.axis.description.OperationDesc[4];
46 _initOperationDesc1();
49 private java.util.Vector cachedSerClasses = new java.util.Vector();
51 private java.util.Vector cachedSerQNames = new java.util.Vector();
53 private java.util.Vector cachedSerFactories = new java.util.Vector();
55 private java.util.Vector cachedDeserFactories = new java.util.Vector();
57 public MuscleWSSoapBindingStub() throws org.apache.axis.AxisFault
62 public MuscleWSSoapBindingStub(java.net.URL endpointURL,
63 javax.xml.rpc.Service service) throws org.apache.axis.AxisFault
66 super.cachedEndpoint = endpointURL;
69 public MuscleWSSoapBindingStub(javax.xml.rpc.Service service)
70 throws org.apache.axis.AxisFault
74 super.service = new org.apache.axis.client.Service();
78 super.service = service;
82 javax.xml.namespace.QName qName;
83 java.lang.Class beansf = org.apache.axis.encoding.ser.BeanSerializerFactory.class;
84 java.lang.Class beandf = org.apache.axis.encoding.ser.BeanDeserializerFactory.class;
85 // java.lang.Class enumsf =
86 // org.apache.axis.encoding.ser.EnumSerializerFactory.class;
87 // java.lang.Class enumdf =
88 // org.apache.axis.encoding.ser.EnumDeserializerFactory.class;
89 java.lang.Class arraysf = org.apache.axis.encoding.ser.ArraySerializerFactory.class;
90 java.lang.Class arraydf = org.apache.axis.encoding.ser.ArrayDeserializerFactory.class;
91 // java.lang.Class simplesf =
92 // org.apache.axis.encoding.ser.SimpleSerializerFactory.class;
93 // java.lang.Class simpledf =
94 // org.apache.axis.encoding.ser.SimpleDeserializerFactory.class;
95 // java.lang.Class simplelistsf =
96 // org.apache.axis.encoding.ser.SimpleListSerializerFactory.class;
97 // java.lang.Class simplelistdf =
98 // org.apache.axis.encoding.ser.SimpleListDeserializerFactory.class;
99 qName = new javax.xml.namespace.QName("simple.objects.vamsas",
101 cachedSerQNames.add(qName);
102 cls = vamsas.objects.simple.Sequence.class;
103 cachedSerClasses.add(cls);
104 cachedSerFactories.add(beansf);
105 cachedDeserFactories.add(beandf);
107 qName = new javax.xml.namespace.QName("vamsas", "ArrayOf_tns1_Sequence");
108 cachedSerQNames.add(qName);
109 cls = vamsas.objects.simple.Sequence[].class;
110 cachedSerClasses.add(cls);
111 cachedSerFactories.add(arraysf);
112 cachedDeserFactories.add(arraydf);
114 qName = new javax.xml.namespace.QName("simple.objects.vamsas",
116 cachedSerQNames.add(qName);
117 cls = vamsas.objects.simple.MsaResult.class;
118 cachedSerClasses.add(cls);
119 cachedSerFactories.add(beansf);
120 cachedDeserFactories.add(beandf);
122 qName = new javax.xml.namespace.QName("simple.objects.vamsas",
124 cachedSerQNames.add(qName);
125 cls = vamsas.objects.simple.SequenceSet.class;
126 cachedSerClasses.add(cls);
127 cachedSerFactories.add(beansf);
128 cachedDeserFactories.add(beandf);
130 qName = new javax.xml.namespace.QName("http://simple.objects.vamsas",
132 cachedSerQNames.add(qName);
133 cls = vamsas.objects.simple.Object.class;
134 cachedSerClasses.add(cls);
135 cachedSerFactories.add(beansf);
136 cachedDeserFactories.add(beandf);
138 qName = new javax.xml.namespace.QName("simple.objects.vamsas",
140 cachedSerQNames.add(qName);
141 cls = vamsas.objects.simple.Alignment.class;
142 cachedSerClasses.add(cls);
143 cachedSerFactories.add(beansf);
144 cachedDeserFactories.add(beandf);
146 qName = new javax.xml.namespace.QName("simple.objects.vamsas",
148 cachedSerQNames.add(qName);
149 cls = vamsas.objects.simple.WsJobId.class;
150 cachedSerClasses.add(cls);
151 cachedSerFactories.add(beansf);
152 cachedDeserFactories.add(beandf);
154 qName = new javax.xml.namespace.QName("vamsas", "ArrayOf_xsd_string");
155 cachedSerQNames.add(qName);
156 cls = java.lang.String[].class;
157 cachedSerClasses.add(cls);
158 cachedSerFactories.add(arraysf);
159 cachedDeserFactories.add(arraydf);
161 qName = new javax.xml.namespace.QName("simple.objects.vamsas", "Result");
162 cachedSerQNames.add(qName);
163 cls = vamsas.objects.simple.Result.class;
164 cachedSerClasses.add(cls);
165 cachedSerFactories.add(beansf);
166 cachedDeserFactories.add(beandf);
169 private static void _initOperationDesc1()
171 org.apache.axis.description.OperationDesc oper;
172 oper = new org.apache.axis.description.OperationDesc();
173 oper.setName("align");
174 oper.addParameter(new javax.xml.namespace.QName("", "seqSet"),
175 new javax.xml.namespace.QName("simple.objects.vamsas",
177 vamsas.objects.simple.SequenceSet.class,
178 org.apache.axis.description.ParameterDesc.IN, false, false);
179 oper.setReturnType(new javax.xml.namespace.QName(
180 "simple.objects.vamsas", "WsJobId"));
181 oper.setReturnClass(vamsas.objects.simple.WsJobId.class);
182 oper.setReturnQName(new javax.xml.namespace.QName("", "alignReturn"));
183 oper.setStyle(org.apache.axis.constants.Style.RPC);
184 oper.setUse(org.apache.axis.constants.Use.ENCODED);
185 _operations[0] = oper;
187 oper = new org.apache.axis.description.OperationDesc();
188 oper.setName("getalign");
189 oper.addParameter(new javax.xml.namespace.QName("", "job_id"),
190 new javax.xml.namespace.QName(
191 "http://www.w3.org/2001/XMLSchema", "string"),
192 java.lang.String.class,
193 org.apache.axis.description.ParameterDesc.IN, false, false);
194 oper.setReturnType(new javax.xml.namespace.QName(
195 "simple.objects.vamsas", "Alignment"));
196 oper.setReturnClass(vamsas.objects.simple.Alignment.class);
198 .setReturnQName(new javax.xml.namespace.QName("",
200 oper.setStyle(org.apache.axis.constants.Style.RPC);
201 oper.setUse(org.apache.axis.constants.Use.ENCODED);
202 _operations[1] = oper;
204 oper = new org.apache.axis.description.OperationDesc();
205 oper.setName("getResult");
206 oper.addParameter(new javax.xml.namespace.QName("", "job_id"),
207 new javax.xml.namespace.QName(
208 "http://www.w3.org/2001/XMLSchema", "string"),
209 java.lang.String.class,
210 org.apache.axis.description.ParameterDesc.IN, false, false);
211 oper.setReturnType(new javax.xml.namespace.QName(
212 "simple.objects.vamsas", "MsaResult"));
213 oper.setReturnClass(vamsas.objects.simple.MsaResult.class);
215 .setReturnQName(new javax.xml.namespace.QName("",
217 oper.setStyle(org.apache.axis.constants.Style.RPC);
218 oper.setUse(org.apache.axis.constants.Use.ENCODED);
219 _operations[2] = oper;
221 oper = new org.apache.axis.description.OperationDesc();
222 oper.setName("cancel");
223 oper.addParameter(new javax.xml.namespace.QName("", "jobId"),
224 new javax.xml.namespace.QName(
225 "http://www.w3.org/2001/XMLSchema", "string"),
226 java.lang.String.class,
227 org.apache.axis.description.ParameterDesc.IN, false, false);
228 oper.setReturnType(new javax.xml.namespace.QName(
229 "simple.objects.vamsas", "WsJobId"));
230 oper.setReturnClass(vamsas.objects.simple.WsJobId.class);
231 oper.setReturnQName(new javax.xml.namespace.QName("", "cancelReturn"));
232 oper.setStyle(org.apache.axis.constants.Style.RPC);
233 oper.setUse(org.apache.axis.constants.Use.ENCODED);
234 _operations[3] = oper;
237 protected org.apache.axis.client.Call createCall()
238 throws java.rmi.RemoteException
242 org.apache.axis.client.Call _call = (org.apache.axis.client.Call) super.service
245 if (super.maintainSessionSet)
247 _call.setMaintainSession(super.maintainSession);
250 if (super.cachedUsername != null)
252 _call.setUsername(super.cachedUsername);
255 if (super.cachedPassword != null)
257 _call.setPassword(super.cachedPassword);
260 if (super.cachedEndpoint != null)
262 _call.setTargetEndpointAddress(super.cachedEndpoint);
265 if (super.cachedTimeout != null)
267 _call.setTimeout(super.cachedTimeout);
270 if (super.cachedPortName != null)
272 _call.setPortName(super.cachedPortName);
275 java.util.Enumeration keys = super.cachedProperties.keys();
277 while (keys.hasMoreElements())
279 java.lang.String key = (java.lang.String) keys.nextElement();
280 _call.setProperty(key, super.cachedProperties.get(key));
283 // All the type mapping information is registered
284 // when the first call is made.
285 // The type mapping information is actually registered in
286 // the TypeMappingRegistry of the service, which
287 // is the reason why registration is only needed for the first call.
292 // must set encoding style before registering serializers
294 .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
295 _call.setEncodingStyle(org.apache.axis.Constants.URI_SOAP11_ENC);
297 for (int i = 0; i < cachedSerFactories.size(); ++i)
299 java.lang.Class cls = (java.lang.Class) cachedSerClasses.get(i);
300 javax.xml.namespace.QName qName = (javax.xml.namespace.QName) cachedSerQNames
302 java.lang.Class sf = (java.lang.Class) cachedSerFactories
304 java.lang.Class df = (java.lang.Class) cachedDeserFactories
306 _call.registerTypeMapping(cls, qName, sf, df, false);
312 } catch (java.lang.Throwable _t)
314 throw new org.apache.axis.AxisFault(
315 "Failure trying to get the Call object", _t);
319 public vamsas.objects.simple.WsJobId align(
320 vamsas.objects.simple.SequenceSet seqSet)
321 throws java.rmi.RemoteException
323 if (super.cachedEndpoint == null)
325 throw new org.apache.axis.NoEndPointException();
328 org.apache.axis.client.Call _call = createCall();
329 _call.setOperation(_operations[0]);
330 _call.setUseSOAPAction(true);
331 _call.setSOAPActionURI("");
333 .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
335 .setOperationName(new javax.xml.namespace.QName("vamsas",
338 setRequestHeaders(_call);
339 setAttachments(_call);
341 java.lang.Object _resp = _call.invoke(new java.lang.Object[]
344 if (_resp instanceof java.rmi.RemoteException)
346 throw (java.rmi.RemoteException) _resp;
350 extractAttachments(_call);
354 return (vamsas.objects.simple.WsJobId) _resp;
355 } catch (java.lang.Exception _exception)
357 return (vamsas.objects.simple.WsJobId) org.apache.axis.utils.JavaUtils
358 .convert(_resp, vamsas.objects.simple.WsJobId.class);
363 public vamsas.objects.simple.Alignment getalign(java.lang.String job_id)
364 throws java.rmi.RemoteException
366 if (super.cachedEndpoint == null)
368 throw new org.apache.axis.NoEndPointException();
371 org.apache.axis.client.Call _call = createCall();
372 _call.setOperation(_operations[1]);
373 _call.setUseSOAPAction(true);
374 _call.setSOAPActionURI("");
376 .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
377 _call.setOperationName(new javax.xml.namespace.QName("vamsas",
380 setRequestHeaders(_call);
381 setAttachments(_call);
383 java.lang.Object _resp = _call.invoke(new java.lang.Object[]
386 if (_resp instanceof java.rmi.RemoteException)
388 throw (java.rmi.RemoteException) _resp;
392 extractAttachments(_call);
396 return (vamsas.objects.simple.Alignment) _resp;
397 } catch (java.lang.Exception _exception)
399 return (vamsas.objects.simple.Alignment) org.apache.axis.utils.JavaUtils
400 .convert(_resp, vamsas.objects.simple.Alignment.class);
405 public vamsas.objects.simple.MsaResult getResult(java.lang.String job_id)
406 throws java.rmi.RemoteException
408 if (super.cachedEndpoint == null)
410 throw new org.apache.axis.NoEndPointException();
413 org.apache.axis.client.Call _call = createCall();
414 _call.setOperation(_operations[2]);
415 _call.setUseSOAPAction(true);
416 _call.setSOAPActionURI("");
418 .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
419 _call.setOperationName(new javax.xml.namespace.QName("vamsas",
422 setRequestHeaders(_call);
423 setAttachments(_call);
425 java.lang.Object _resp = _call.invoke(new java.lang.Object[]
428 if (_resp instanceof java.rmi.RemoteException)
430 throw (java.rmi.RemoteException) _resp;
434 extractAttachments(_call);
438 return (vamsas.objects.simple.MsaResult) _resp;
439 } catch (java.lang.Exception _exception)
441 return (vamsas.objects.simple.MsaResult) org.apache.axis.utils.JavaUtils
442 .convert(_resp, vamsas.objects.simple.MsaResult.class);
447 public vamsas.objects.simple.WsJobId cancel(java.lang.String jobId)
448 throws java.rmi.RemoteException
450 if (super.cachedEndpoint == null)
452 throw new org.apache.axis.NoEndPointException();
455 org.apache.axis.client.Call _call = createCall();
456 _call.setOperation(_operations[3]);
457 _call.setUseSOAPAction(true);
458 _call.setSOAPActionURI("");
460 .setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
462 .setOperationName(new javax.xml.namespace.QName("vamsas",
465 setRequestHeaders(_call);
466 setAttachments(_call);
468 java.lang.Object _resp = _call.invoke(new java.lang.Object[]
471 if (_resp instanceof java.rmi.RemoteException)
473 throw (java.rmi.RemoteException) _resp;
477 extractAttachments(_call);
481 return (vamsas.objects.simple.WsJobId) _resp;
482 } catch (java.lang.Exception _exception)
484 return (vamsas.objects.simple.WsJobId) org.apache.axis.utils.JavaUtils
485 .convert(_resp, vamsas.objects.simple.WsJobId.class);