Mapping to PDB added
[jalview.git] / src / ext / vamsas / RegistryServiceSoapBindingStub.java
1 /**
2  * RegistryServiceSoapBindingStub.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 RegistryServiceSoapBindingStub extends org.apache.axis.client.Stub implements ext.vamsas.IRegistry {
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[1];
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("getServices");
27         oper.setReturnType(new javax.xml.namespace.QName("registry.objects.vamsas", "ServiceHandles"));
28         oper.setReturnClass(ext.vamsas.ServiceHandles.class);
29         oper.setReturnQName(new javax.xml.namespace.QName("", "getServicesReturn"));
30         oper.setStyle(org.apache.axis.constants.Style.RPC);
31         oper.setUse(org.apache.axis.constants.Use.ENCODED);
32         _operations[0] = oper;
33
34     }
35
36     public RegistryServiceSoapBindingStub() throws org.apache.axis.AxisFault {
37          this(null);
38     }
39
40     public RegistryServiceSoapBindingStub(java.net.URL endpointURL, javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
41          this(service);
42          super.cachedEndpoint = endpointURL;
43     }
44
45     public RegistryServiceSoapBindingStub(javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
46         if (service == null) {
47             super.service = new org.apache.axis.client.Service();
48         } else {
49             super.service = service;
50         }
51             java.lang.Class cls;
52             javax.xml.namespace.QName qName;
53             java.lang.Class beansf = org.apache.axis.encoding.ser.BeanSerializerFactory.class;
54             java.lang.Class beandf = org.apache.axis.encoding.ser.BeanDeserializerFactory.class;
55             //java.lang.Class enumsf = org.apache.axis.encoding.ser.EnumSerializerFactory.class;
56             //java.lang.Class enumdf = org.apache.axis.encoding.ser.EnumDeserializerFactory.class;
57             java.lang.Class arraysf = org.apache.axis.encoding.ser.ArraySerializerFactory.class;
58             java.lang.Class arraydf = org.apache.axis.encoding.ser.ArrayDeserializerFactory.class;
59             //java.lang.Class simplesf = org.apache.axis.encoding.ser.SimpleSerializerFactory.class;
60             //java.lang.Class simpledf = org.apache.axis.encoding.ser.SimpleDeserializerFactory.class;
61             //java.lang.Class simplelistsf = org.apache.axis.encoding.ser.SimpleListSerializerFactory.class;
62             //java.lang.Class simplelistdf = org.apache.axis.encoding.ser.SimpleListDeserializerFactory.class;
63             qName = new javax.xml.namespace.QName("vamsas", "ArrayOf_tns1_ServiceHandle");
64             cachedSerQNames.add(qName);
65             cls = ext.vamsas.ServiceHandle[].class;
66             cachedSerClasses.add(cls);
67             cachedSerFactories.add(arraysf);
68             cachedDeserFactories.add(arraydf);
69
70             qName = new javax.xml.namespace.QName("registry.objects.vamsas", "ServiceHandles");
71             cachedSerQNames.add(qName);
72             cls = ext.vamsas.ServiceHandles.class;
73             cachedSerClasses.add(cls);
74             cachedSerFactories.add(beansf);
75             cachedDeserFactories.add(beandf);
76
77             qName = new javax.xml.namespace.QName("registry.objects.vamsas", "ServiceHandle");
78             cachedSerQNames.add(qName);
79             cls = ext.vamsas.ServiceHandle.class;
80             cachedSerClasses.add(cls);
81             cachedSerFactories.add(beansf);
82             cachedDeserFactories.add(beandf);
83
84     }
85
86     protected org.apache.axis.client.Call createCall() throws java.rmi.RemoteException {
87         try {
88             org.apache.axis.client.Call _call =
89                     (org.apache.axis.client.Call) super.service.createCall();
90             if (super.maintainSessionSet) {
91                 _call.setMaintainSession(super.maintainSession);
92             }
93             if (super.cachedUsername != null) {
94                 _call.setUsername(super.cachedUsername);
95             }
96             if (super.cachedPassword != null) {
97                 _call.setPassword(super.cachedPassword);
98             }
99             if (super.cachedEndpoint != null) {
100                 _call.setTargetEndpointAddress(super.cachedEndpoint);
101             }
102             if (super.cachedTimeout != null) {
103                 _call.setTimeout(super.cachedTimeout);
104             }
105             if (super.cachedPortName != null) {
106                 _call.setPortName(super.cachedPortName);
107             }
108             java.util.Enumeration keys = super.cachedProperties.keys();
109             while (keys.hasMoreElements()) {
110                 java.lang.String key = (java.lang.String) keys.nextElement();
111                 _call.setProperty(key, super.cachedProperties.get(key));
112             }
113             // All the type mapping information is registered
114             // when the first call is made.
115             // The type mapping information is actually registered in
116             // the TypeMappingRegistry of the service, which
117             // is the reason why registration is only needed for the first call.
118             synchronized (this) {
119                 if (firstCall()) {
120                     // must set encoding style before registering serializers
121                     _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
122                     _call.setEncodingStyle(org.apache.axis.Constants.URI_SOAP11_ENC);
123                     for (int i = 0; i < cachedSerFactories.size(); ++i) {
124                         java.lang.Class cls = (java.lang.Class) cachedSerClasses.get(i);
125                         javax.xml.namespace.QName qName =
126                                 (javax.xml.namespace.QName) cachedSerQNames.get(i);
127                         java.lang.Class sf = (java.lang.Class)
128                                  cachedSerFactories.get(i);
129                         java.lang.Class df = (java.lang.Class)
130                                  cachedDeserFactories.get(i);
131                         _call.registerTypeMapping(cls, qName, sf, df, false);
132                     }
133                 }
134             }
135             return _call;
136         }
137         catch (java.lang.Throwable _t) {
138             throw new org.apache.axis.AxisFault("Failure trying to get the Call object", _t);
139         }
140     }
141
142     public ext.vamsas.ServiceHandles getServices() throws java.rmi.RemoteException {
143         if (super.cachedEndpoint == null) {
144             throw new org.apache.axis.NoEndPointException();
145         }
146         org.apache.axis.client.Call _call = createCall();
147         _call.setOperation(_operations[0]);
148         _call.setUseSOAPAction(true);
149         _call.setSOAPActionURI("");
150         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
151         _call.setOperationName(new javax.xml.namespace.QName("vamsas", "getServices"));
152
153         setRequestHeaders(_call);
154         setAttachments(_call);
155         java.lang.Object _resp = _call.invoke(new java.lang.Object[] {});
156
157         if (_resp instanceof java.rmi.RemoteException) {
158             throw (java.rmi.RemoteException)_resp;
159         }
160         else {
161             extractAttachments(_call);
162             try {
163                 return (ext.vamsas.ServiceHandles) _resp;
164             } catch (java.lang.Exception _exception) {
165                 return (ext.vamsas.ServiceHandles) org.apache.axis.utils.JavaUtils.convert(_resp, ext.vamsas.ServiceHandles.class);
166             }
167         }
168     }
169
170 }