001: /**
002: * Doc_Test_BindingStub.java
003: *
004: * This file was auto-generated from WSDL
005: * by the Apache Axis WSDL2Java emitter.
006: */package interop.wsifservice;
007:
008: public class Doc_Test_BindingStub extends org.apache.axis.client.Stub
009: implements interop.wsifservice.Doc_TestPortType {
010: private java.util.Vector cachedSerClasses = new java.util.Vector();
011: private java.util.Vector cachedSerQNames = new java.util.Vector();
012: private java.util.Vector cachedSerFactories = new java.util.Vector();
013: private java.util.Vector cachedDeserFactories = new java.util.Vector();
014:
015: public Doc_Test_BindingStub() throws org.apache.axis.AxisFault {
016: this (null);
017: }
018:
019: public Doc_Test_BindingStub(java.net.URL endpointURL,
020: javax.xml.rpc.Service service)
021: throws org.apache.axis.AxisFault {
022: this (service);
023: super .cachedEndpoint = endpointURL;
024: }
025:
026: public Doc_Test_BindingStub(javax.xml.rpc.Service service)
027: throws org.apache.axis.AxisFault {
028: if (service == null) {
029: super .service = new org.apache.axis.client.Service();
030: } else {
031: super .service = service;
032: }
033: java.lang.Class cls;
034: javax.xml.namespace.QName qName;
035: java.lang.Class beansf = org.apache.axis.encoding.ser.BeanSerializerFactory.class;
036: java.lang.Class beandf = org.apache.axis.encoding.ser.BeanDeserializerFactory.class;
037: java.lang.Class enumsf = org.apache.axis.encoding.ser.EnumSerializerFactory.class;
038: java.lang.Class enumdf = org.apache.axis.encoding.ser.EnumDeserializerFactory.class;
039: java.lang.Class arraysf = org.apache.axis.encoding.ser.ArraySerializerFactory.class;
040: java.lang.Class arraydf = org.apache.axis.encoding.ser.ArrayDeserializerFactory.class;
041: java.lang.Class simplesf = org.apache.axis.encoding.ser.SimpleSerializerFactory.class;
042: java.lang.Class simpledf = org.apache.axis.encoding.ser.SimpleDeserializerFactory.class;
043: qName = new javax.xml.namespace.QName(
044: "http://soapinterop.org/", "ArrayOfSimpleDocument");
045: cachedSerQNames.add(qName);
046: cls = interop.wsifservice.ArrayOfSimpleDocument.class;
047: cachedSerClasses.add(cls);
048: cachedSerFactories.add(beansf);
049: cachedDeserFactories.add(beandf);
050:
051: qName = new javax.xml.namespace.QName(
052: "http://soapinterop.org/", "ChildDocument");
053: cachedSerQNames.add(qName);
054: cls = interop.wsifservice.ChildDocument.class;
055: cachedSerClasses.add(cls);
056: cachedSerFactories.add(beansf);
057: cachedDeserFactories.add(beandf);
058:
059: qName = new javax.xml.namespace.QName(
060: "http://soapinterop.org/", "SingleTag");
061: cachedSerQNames.add(qName);
062: cls = interop.wsifservice.SingleTag_Type.class;
063: cachedSerClasses.add(cls);
064: cachedSerFactories.add(beansf);
065: cachedDeserFactories.add(beandf);
066:
067: qName = new javax.xml.namespace.QName(
068: "http://soapinterop.org/", "ComplexDocument");
069: cachedSerQNames.add(qName);
070: cls = interop.wsifservice.ComplexDocument_Type.class;
071: cachedSerClasses.add(cls);
072: cachedSerFactories.add(beansf);
073: cachedDeserFactories.add(beandf);
074:
075: qName = new javax.xml.namespace.QName(
076: "http://soapinterop.org/", "SimpleDocument");
077: cachedSerQNames.add(qName);
078: cls = interop.wsifservice.SimpleDocument_Type.class;
079: cachedSerClasses.add(cls);
080: cachedSerFactories.add(simplesf);
081: cachedDeserFactories.add(simpledf);
082:
083: }
084:
085: private org.apache.axis.client.Call createCall()
086: throws java.rmi.RemoteException {
087: try {
088: org.apache.axis.client.Call _call = (org.apache.axis.client.Call) super .service
089: .createCall();
090: if (super .maintainSessionSet) {
091: _call.setMaintainSession(super .maintainSession);
092: }
093: if (super .cachedUsername != null) {
094: _call.setUsername(super .cachedUsername);
095: }
096: if (super .cachedPassword != null) {
097: _call.setPassword(super .cachedPassword);
098: }
099: 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
111: .nextElement();
112: if (_call.isPropertySupported(key))
113: _call.setProperty(key, super .cachedProperties
114: .get(key));
115: else
116: _call.setScopedProperty(key, super .cachedProperties
117: .get(key));
118: }
119: // All the type mapping information is registered
120: // when the first call is made.
121: // The type mapping information is actually registered in
122: // the TypeMappingRegistry of the service, which
123: // is the reason why registration is only needed for the first call.
124: synchronized (this ) {
125: if (firstCall()) {
126: // must set encoding style before registering serializers
127: _call.setEncodingStyle(null);
128: for (int i = 0; i < cachedSerFactories.size(); ++i) {
129: java.lang.Class cls = (java.lang.Class) cachedSerClasses
130: .get(i);
131: javax.xml.namespace.QName qName = (javax.xml.namespace.QName) cachedSerQNames
132: .get(i);
133: java.lang.Class sf = (java.lang.Class) cachedSerFactories
134: .get(i);
135: java.lang.Class df = (java.lang.Class) cachedDeserFactories
136: .get(i);
137: _call.registerTypeMapping(cls, qName, sf, df,
138: false);
139: }
140: }
141: }
142: return _call;
143: } catch (java.lang.Throwable t) {
144: throw new org.apache.axis.AxisFault(
145: "Failure trying to get the Call object", t);
146: }
147: }
148:
149: public interop.wsifservice.SingleTag_Type singleTag(
150: interop.wsifservice.SingleTag_Type singleTag)
151: throws java.rmi.RemoteException {
152: if (super .cachedEndpoint == null) {
153: throw new org.apache.axis.NoEndPointException();
154: }
155: org.apache.axis.client.Call _call = createCall();
156: _call.addParameter(new javax.xml.namespace.QName(
157: "http://soapinterop.org/", "SingleTag"),
158: new javax.xml.namespace.QName(
159: "http://soapinterop.org/", "SingleTag"),
160: interop.wsifservice.SingleTag_Type.class,
161: javax.xml.rpc.ParameterMode.IN);
162: _call.setReturnType(new javax.xml.namespace.QName(
163: "http://soapinterop.org/", "SingleTag"),
164: interop.wsifservice.SingleTag_Type.class);
165: _call.setUseSOAPAction(true);
166: _call.setSOAPActionURI("http://soapinterop.org/SingleTag");
167: _call.setEncodingStyle(null);
168: _call.setScopedProperty(
169: org.apache.axis.client.Call.SEND_TYPE_ATTR,
170: Boolean.FALSE);
171: _call.setScopedProperty(
172: org.apache.axis.AxisEngine.PROP_DOMULTIREFS,
173: Boolean.FALSE);
174: _call.setOperationStyle("wrapped");
175: _call.setOperationName(new javax.xml.namespace.QName(
176: "http://soapinterop.org/", "SingleTag"));
177: _call.setReturnQName(new javax.xml.namespace.QName(
178: "http://soapinterop.org/", "SingleTag"));
179:
180: java.lang.Object _resp = _call
181: .invoke(new java.lang.Object[] { singleTag });
182:
183: if (_resp instanceof java.rmi.RemoteException) {
184: throw (java.rmi.RemoteException) _resp;
185: } else {
186: try {
187: return (interop.wsifservice.SingleTag_Type) _resp;
188: } catch (java.lang.Exception _exception) {
189: return (interop.wsifservice.SingleTag_Type) org.apache.axis.utils.JavaUtils
190: .convert(
191: _resp,
192: interop.wsifservice.SingleTag_Type.class);
193: }
194: }
195: }
196:
197: public interop.wsifservice.SimpleDocument_Type simpleDocument(
198: interop.wsifservice.SimpleDocument_Type simpleDocument)
199: throws java.rmi.RemoteException {
200: if (super .cachedEndpoint == null) {
201: throw new org.apache.axis.NoEndPointException();
202: }
203: org.apache.axis.client.Call _call = createCall();
204: _call.addParameter(new javax.xml.namespace.QName(
205: "http://soapinterop.org/", "SimpleDocument"),
206: new javax.xml.namespace.QName(
207: "http://soapinterop.org/", "SimpleDocument"),
208: interop.wsifservice.SimpleDocument_Type.class,
209: javax.xml.rpc.ParameterMode.IN);
210: _call.setReturnType(new javax.xml.namespace.QName(
211: "http://soapinterop.org/", "SimpleDocument"),
212: interop.wsifservice.SimpleDocument_Type.class);
213: _call.setUseSOAPAction(true);
214: _call.setSOAPActionURI("http://soapinterop.org/SimpleDocument");
215: _call.setEncodingStyle(null);
216: _call.setScopedProperty(
217: org.apache.axis.client.Call.SEND_TYPE_ATTR,
218: Boolean.FALSE);
219: _call.setScopedProperty(
220: org.apache.axis.AxisEngine.PROP_DOMULTIREFS,
221: Boolean.FALSE);
222: _call.setOperationStyle("wrapped");
223: _call.setOperationName(new javax.xml.namespace.QName(
224: "http://soapinterop.org/", "SimpleDocument"));
225: _call.setReturnQName(new javax.xml.namespace.QName(
226: "http://soapinterop.org/", "SimpleDocument"));
227:
228: java.lang.Object _resp = _call
229: .invoke(new java.lang.Object[] { simpleDocument });
230:
231: if (_resp instanceof java.rmi.RemoteException) {
232: throw (java.rmi.RemoteException) _resp;
233: } else {
234: try {
235: return (interop.wsifservice.SimpleDocument_Type) _resp;
236: } catch (java.lang.Exception _exception) {
237: return (interop.wsifservice.SimpleDocument_Type) org.apache.axis.utils.JavaUtils
238: .convert(
239: _resp,
240: interop.wsifservice.SimpleDocument_Type.class);
241: }
242: }
243: }
244:
245: public interop.wsifservice.ComplexDocument_Type complexDocument(
246: interop.wsifservice.ComplexDocument_Type complexDocument)
247: throws java.rmi.RemoteException {
248: if (super .cachedEndpoint == null) {
249: throw new org.apache.axis.NoEndPointException();
250: }
251: org.apache.axis.client.Call _call = createCall();
252: _call.addParameter(new javax.xml.namespace.QName(
253: "http://soapinterop.org/", "ComplexDocument"),
254: new javax.xml.namespace.QName(
255: "http://soapinterop.org/", "ComplexDocument"),
256: interop.wsifservice.ComplexDocument_Type.class,
257: javax.xml.rpc.ParameterMode.IN);
258: _call.setReturnType(new javax.xml.namespace.QName(
259: "http://soapinterop.org/", "ComplexDocument"),
260: interop.wsifservice.ComplexDocument_Type.class);
261: _call.setUseSOAPAction(true);
262: _call
263: .setSOAPActionURI("http://soapinterop.org/ComplexDocument");
264: _call.setEncodingStyle(null);
265: _call.setScopedProperty(
266: org.apache.axis.client.Call.SEND_TYPE_ATTR,
267: Boolean.FALSE);
268: _call.setScopedProperty(
269: org.apache.axis.AxisEngine.PROP_DOMULTIREFS,
270: Boolean.FALSE);
271: _call.setOperationStyle("wrapped");
272: _call.setOperationName(new javax.xml.namespace.QName(
273: "http://soapinterop.org/", "ComplexDocument"));
274: _call.setReturnQName(new javax.xml.namespace.QName(
275: "http://soapinterop.org/", "ComplexDocument"));
276:
277: java.lang.Object _resp = _call
278: .invoke(new java.lang.Object[] { complexDocument });
279:
280: if (_resp instanceof java.rmi.RemoteException) {
281: throw (java.rmi.RemoteException) _resp;
282: } else {
283: try {
284: return (interop.wsifservice.ComplexDocument_Type) _resp;
285: } catch (java.lang.Exception _exception) {
286: return (interop.wsifservice.ComplexDocument_Type) org.apache.axis.utils.JavaUtils
287: .convert(
288: _resp,
289: interop.wsifservice.ComplexDocument_Type.class);
290: }
291: }
292: }
293:
294: }
|