1   /**
2    * Portlet_MB_MBThreadServiceSoapBindingStub.java
3    *
4    * This file was auto-generated from WSDL
5    * by the Apache Axis 1.4 Apr 22, 2006 (06:55:48 PDT) WSDL2Java emitter.
6    */
7   
8   package com.liferay.client.soap.portlet.messageboards.service.http;
9   
10  public class Portlet_MB_MBThreadServiceSoapBindingStub extends org.apache.axis.client.Stub implements com.liferay.client.soap.portlet.messageboards.service.http.MBThreadServiceSoap {
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[2];
20          _initOperationDesc1();
21      }
22  
23      private static void _initOperationDesc1(){
24          org.apache.axis.description.OperationDesc oper;
25          org.apache.axis.description.ParameterDesc param;
26          oper = new org.apache.axis.description.OperationDesc();
27          oper.setName("moveThread");
28          param = new org.apache.axis.description.ParameterDesc(new javax.xml.namespace.QName("", "categoryId"), org.apache.axis.description.ParameterDesc.IN, new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "long"), long.class, false, false);
29          oper.addParameter(param);
30          param = new org.apache.axis.description.ParameterDesc(new javax.xml.namespace.QName("", "threadId"), org.apache.axis.description.ParameterDesc.IN, new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "long"), long.class, false, false);
31          oper.addParameter(param);
32          oper.setReturnType(new javax.xml.namespace.QName("http://model.messageboards.portlet.liferay.com", "MBThreadSoap"));
33          oper.setReturnClass(com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap.class);
34          oper.setReturnQName(new javax.xml.namespace.QName("", "moveThreadReturn"));
35          oper.setStyle(org.apache.axis.constants.Style.RPC);
36          oper.setUse(org.apache.axis.constants.Use.ENCODED);
37          _operations[0] = oper;
38  
39          oper = new org.apache.axis.description.OperationDesc();
40          oper.setName("splitThread");
41          param = new org.apache.axis.description.ParameterDesc(new javax.xml.namespace.QName("", "messageId"), org.apache.axis.description.ParameterDesc.IN, new javax.xml.namespace.QName("http://www.w3.org/2001/XMLSchema", "long"), long.class, false, false);
42          oper.addParameter(param);
43          param = new org.apache.axis.description.ParameterDesc(new javax.xml.namespace.QName("", "serviceContext"), org.apache.axis.description.ParameterDesc.IN, new javax.xml.namespace.QName("http://service.portal.liferay.com", "ServiceContext"), com.liferay.client.soap.portal.service.ServiceContext.class, false, false);
44          oper.addParameter(param);
45          oper.setReturnType(new javax.xml.namespace.QName("http://model.messageboards.portlet.liferay.com", "MBThreadSoap"));
46          oper.setReturnClass(com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap.class);
47          oper.setReturnQName(new javax.xml.namespace.QName("", "splitThreadReturn"));
48          oper.setStyle(org.apache.axis.constants.Style.RPC);
49          oper.setUse(org.apache.axis.constants.Use.ENCODED);
50          _operations[1] = oper;
51  
52      }
53  
54      public Portlet_MB_MBThreadServiceSoapBindingStub() throws org.apache.axis.AxisFault {
55           this(null);
56      }
57  
58      public Portlet_MB_MBThreadServiceSoapBindingStub(java.net.URL endpointURL, javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
59           this(service);
60           super.cachedEndpoint = endpointURL;
61      }
62  
63      public Portlet_MB_MBThreadServiceSoapBindingStub(javax.xml.rpc.Service service) throws org.apache.axis.AxisFault {
64          if (service == null) {
65              super.service = new org.apache.axis.client.Service();
66          } else {
67              super.service = service;
68          }
69          ((org.apache.axis.client.Service)super.service).setTypeMappingVersion("1.2");
70              java.lang.Class cls;
71              javax.xml.namespace.QName qName;
72              javax.xml.namespace.QName qName2;
73              java.lang.Class beansf = org.apache.axis.encoding.ser.BeanSerializerFactory.class;
74              java.lang.Class beandf = org.apache.axis.encoding.ser.BeanDeserializerFactory.class;
75              java.lang.Class enumsf = org.apache.axis.encoding.ser.EnumSerializerFactory.class;
76              java.lang.Class enumdf = org.apache.axis.encoding.ser.EnumDeserializerFactory.class;
77              java.lang.Class arraysf = org.apache.axis.encoding.ser.ArraySerializerFactory.class;
78              java.lang.Class arraydf = org.apache.axis.encoding.ser.ArrayDeserializerFactory.class;
79              java.lang.Class simplesf = org.apache.axis.encoding.ser.SimpleSerializerFactory.class;
80              java.lang.Class simpledf = org.apache.axis.encoding.ser.SimpleDeserializerFactory.class;
81              java.lang.Class simplelistsf = org.apache.axis.encoding.ser.SimpleListSerializerFactory.class;
82              java.lang.Class simplelistdf = org.apache.axis.encoding.ser.SimpleListDeserializerFactory.class;
83              qName = new javax.xml.namespace.QName("http://model.messageboards.portlet.liferay.com", "MBThreadSoap");
84              cachedSerQNames.add(qName);
85              cls = com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap.class;
86              cachedSerClasses.add(cls);
87              cachedSerFactories.add(beansf);
88              cachedDeserFactories.add(beandf);
89  
90              qName = new javax.xml.namespace.QName("http://model.portal.liferay.com", "PortletPreferencesIds");
91              cachedSerQNames.add(qName);
92              cls = com.liferay.client.soap.portal.model.PortletPreferencesIds.class;
93              cachedSerClasses.add(cls);
94              cachedSerFactories.add(beansf);
95              cachedDeserFactories.add(beandf);
96  
97              qName = new javax.xml.namespace.QName("http://service.portal.liferay.com", "ServiceContext");
98              cachedSerQNames.add(qName);
99              cls = com.liferay.client.soap.portal.service.ServiceContext.class;
100             cachedSerClasses.add(cls);
101             cachedSerFactories.add(beansf);
102             cachedDeserFactories.add(beandf);
103 
104             qName = new javax.xml.namespace.QName("urn:http.service.messageboards.portlet.liferay.com", "ArrayOf_xsd_string");
105             cachedSerQNames.add(qName);
106             cls = java.lang.String[].class;
107             cachedSerClasses.add(cls);
108             qName = new javax.xml.namespace.QName("http://schemas.xmlsoap.org/soap/encoding/", "string");
109             qName2 = null;
110             cachedSerFactories.add(new org.apache.axis.encoding.ser.ArraySerializerFactory(qName, qName2));
111             cachedDeserFactories.add(new org.apache.axis.encoding.ser.ArrayDeserializerFactory());
112 
113     }
114 
115     protected org.apache.axis.client.Call createCall() throws java.rmi.RemoteException {
116         try {
117             org.apache.axis.client.Call _call = super._createCall();
118             if (super.maintainSessionSet) {
119                 _call.setMaintainSession(super.maintainSession);
120             }
121             if (super.cachedUsername != null) {
122                 _call.setUsername(super.cachedUsername);
123             }
124             if (super.cachedPassword != null) {
125                 _call.setPassword(super.cachedPassword);
126             }
127             if (super.cachedEndpoint != null) {
128                 _call.setTargetEndpointAddress(super.cachedEndpoint);
129             }
130             if (super.cachedTimeout != null) {
131                 _call.setTimeout(super.cachedTimeout);
132             }
133             if (super.cachedPortName != null) {
134                 _call.setPortName(super.cachedPortName);
135             }
136             java.util.Enumeration keys = super.cachedProperties.keys();
137             while (keys.hasMoreElements()) {
138                 java.lang.String key = (java.lang.String) keys.nextElement();
139                 _call.setProperty(key, super.cachedProperties.get(key));
140             }
141             // All the type mapping information is registered
142             // when the first call is made.
143             // The type mapping information is actually registered in
144             // the TypeMappingRegistry of the service, which
145             // is the reason why registration is only needed for the first call.
146             synchronized (this) {
147                 if (firstCall()) {
148                     // must set encoding style before registering serializers
149                     _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
150                     _call.setEncodingStyle(org.apache.axis.Constants.URI_SOAP11_ENC);
151                     for (int i = 0; i < cachedSerFactories.size(); ++i) {
152                         java.lang.Class cls = (java.lang.Class) cachedSerClasses.get(i);
153                         javax.xml.namespace.QName qName =
154                                 (javax.xml.namespace.QName) cachedSerQNames.get(i);
155                         java.lang.Object x = cachedSerFactories.get(i);
156                         if (x instanceof Class) {
157                             java.lang.Class sf = (java.lang.Class)
158                                  cachedSerFactories.get(i);
159                             java.lang.Class df = (java.lang.Class)
160                                  cachedDeserFactories.get(i);
161                             _call.registerTypeMapping(cls, qName, sf, df, false);
162                         }
163                         else if (x instanceof javax.xml.rpc.encoding.SerializerFactory) {
164                             org.apache.axis.encoding.SerializerFactory sf = (org.apache.axis.encoding.SerializerFactory)
165                                  cachedSerFactories.get(i);
166                             org.apache.axis.encoding.DeserializerFactory df = (org.apache.axis.encoding.DeserializerFactory)
167                                  cachedDeserFactories.get(i);
168                             _call.registerTypeMapping(cls, qName, sf, df, false);
169                         }
170                     }
171                 }
172             }
173             return _call;
174         }
175         catch (java.lang.Throwable _t) {
176             throw new org.apache.axis.AxisFault("Failure trying to get the Call object", _t);
177         }
178     }
179 
180     public com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap moveThread(long categoryId, long threadId) throws java.rmi.RemoteException {
181         if (super.cachedEndpoint == null) {
182             throw new org.apache.axis.NoEndPointException();
183         }
184         org.apache.axis.client.Call _call = createCall();
185         _call.setOperation(_operations[0]);
186         _call.setUseSOAPAction(true);
187         _call.setSOAPActionURI("");
188         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
189         _call.setOperationName(new javax.xml.namespace.QName("urn:http.service.messageboards.portlet.liferay.com", "moveThread"));
190 
191         setRequestHeaders(_call);
192         setAttachments(_call);
193  try {        java.lang.Object _resp = _call.invoke(new java.lang.Object[] {new java.lang.Long(categoryId), new java.lang.Long(threadId)});
194 
195         if (_resp instanceof java.rmi.RemoteException) {
196             throw (java.rmi.RemoteException)_resp;
197         }
198         else {
199             extractAttachments(_call);
200             try {
201                 return (com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap) _resp;
202             } catch (java.lang.Exception _exception) {
203                 return (com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap) org.apache.axis.utils.JavaUtils.convert(_resp, com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap.class);
204             }
205         }
206   } catch (org.apache.axis.AxisFault axisFaultException) {
207   throw axisFaultException;
208 }
209     }
210 
211     public com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap splitThread(long messageId, com.liferay.client.soap.portal.service.ServiceContext serviceContext) throws java.rmi.RemoteException {
212         if (super.cachedEndpoint == null) {
213             throw new org.apache.axis.NoEndPointException();
214         }
215         org.apache.axis.client.Call _call = createCall();
216         _call.setOperation(_operations[1]);
217         _call.setUseSOAPAction(true);
218         _call.setSOAPActionURI("");
219         _call.setSOAPVersion(org.apache.axis.soap.SOAPConstants.SOAP11_CONSTANTS);
220         _call.setOperationName(new javax.xml.namespace.QName("urn:http.service.messageboards.portlet.liferay.com", "splitThread"));
221 
222         setRequestHeaders(_call);
223         setAttachments(_call);
224  try {        java.lang.Object _resp = _call.invoke(new java.lang.Object[] {new java.lang.Long(messageId), serviceContext});
225 
226         if (_resp instanceof java.rmi.RemoteException) {
227             throw (java.rmi.RemoteException)_resp;
228         }
229         else {
230             extractAttachments(_call);
231             try {
232                 return (com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap) _resp;
233             } catch (java.lang.Exception _exception) {
234                 return (com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap) org.apache.axis.utils.JavaUtils.convert(_resp, com.liferay.client.soap.portlet.messageboards.model.MBThreadSoap.class);
235             }
236         }
237   } catch (org.apache.axis.AxisFault axisFaultException) {
238   throw axisFaultException;
239 }
240     }
241 
242 }
243