ws-axis-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nadira...@apache.org
Subject svn commit: r391689 - in /webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c: ParamCFileWriter.java literal/ClientStubHeaderWriter.java literal/ClientStubWriter.java
Date Wed, 05 Apr 2006 17:52:07 GMT
Author: nadiramra
Date: Wed Apr  5 10:52:05 2006
New Revision: 391689

URL: http://svn.apache.org/viewcvs?rev=391689&view=rev
Log:
C support fixes/enhancements.

Modified:
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParamCFileWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubHeaderWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubWriter.java

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParamCFileWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParamCFileWriter.java?rev=391689&r1=391688&r2=391689&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParamCFileWriter.java
(original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParamCFileWriter.java
Wed Apr  5 10:52:05 2006
@@ -99,18 +99,12 @@
      */
     protected File getFilePath() throws WrapperFault
     {
-        String targetOutputLocation =
-            this.wscontext.getWrapInfo().getTargetOutputLocation();
+        String targetOutputLocation = this.wscontext.getWrapInfo().getTargetOutputLocation();
         if (targetOutputLocation.endsWith("/"))
-        {
-            targetOutputLocation =
-                targetOutputLocation.substring(
-                    0,
-                    targetOutputLocation.length() - 1);
-        }
+            targetOutputLocation = targetOutputLocation.substring(0,targetOutputLocation.length()
- 1);
+
         new File(targetOutputLocation).mkdirs();
-        String fileName =
-            targetOutputLocation + "/" + this.classname + CUtils.C_FILE_SUFFIX;
+        String fileName = targetOutputLocation + "/" + this.classname + CUtils.C_FILE_SUFFIX;
         this.wscontext.addGeneratedFile(classname + CUtils.C_FILE_SUFFIX);
         return new File(fileName);
     }
@@ -124,21 +118,21 @@
         {
             writer.write("#include <stdlib.h>\n");
             writer.write("#include <memory.h>\n");
-            writer.write(
-                "#include \""
-                    + this.classname
-                    + CUtils.C_HEADER_SUFFIX
-                    + "\"\n");
-		writer.write("#include <axis/GDefine.h>\n");
-		writer.write("#include <axis/AxisUserAPI.h>\n");
-		writer.write("#include <axis/SoapEnvVersions.h>\n");
-		writer.write("#include <axis/WSDDDefines.h>\n");
-		writer.write("#include <axis/TypeMapping.h>\n");
-		writer.write("#include <axis/client/Stub.h>\n");
-		writer.write("#include <axis/client/Call.h>\n");
+            writer.write("\n");
+
+            writer.write("#include <axis/GDefine.h>\n");
+            writer.write("#include <axis/AxisUserAPI.h>\n");
+            writer.write("#include <axis/SoapEnvVersions.h>\n");
+            writer.write("#include <axis/WSDDDefines.h>\n");
+            writer.write("#include <axis/TypeMapping.h>\n");
             writer.write("#include <axis/AxisWrapperAPI.h>\n\n");
-		writer.write("#include <axis/IWrapperSoapSerializer.h>\n");
-		writer.write("#include <axis/IWrapperSoapDeSerializer.h>\n");
+            writer.write("#include <axis/IWrapperSoapSerializer.h>\n");
+            writer.write("#include <axis/IWrapperSoapDeSerializer.h>\n");
+            writer.write("#include <axis/client/Stub.h>\n");
+            writer.write("#include <axis/client/Call.h>\n");
+            writer.write("\n");
+            
+            writer.write("#include \"" + this.classname + CUtils.C_HEADER_SUFFIX + "\"\n");
         }
         catch (IOException e)
         {

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubHeaderWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubHeaderWriter.java?rev=391689&r1=391688&r2=391689&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubHeaderWriter.java
(original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubHeaderWriter.java
Wed Apr  5 10:52:05 2006
@@ -59,7 +59,8 @@
             writer.write("#include <axis/TypeMapping.h>\n");
             writer.write("#include <axis/client/Stub.h>\n");
             writer.write("#include <axis/client/Call.h>\n");
-
+            writer.write("\n");
+            
             Type atype;
             Iterator types = this.wscontext.getTypemap().getTypes().iterator();
             Vector typeSet = new Vector();

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubWriter.java?rev=391689&r1=391688&r2=391689&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubWriter.java
(original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/ClientStubWriter.java
Wed Apr  5 10:52:05 2006
@@ -236,9 +236,9 @@
             }
         }
         
-        writer.write ("\tconst char* pcCmplxFaultName;\n");
-        writer.write ("\tpcCmplxFaultName = NULL;\n");
-
+        writer.write ("\tconst char* pcCmplxFaultName = NULL;\n");
+        writer.write("\n");
+        
         writer.write("\t/* Following will establish the connections with the server too */\n");
         writer.write("\tif (AXISC_SUCCESS != axiscInitializeCall(call, C_DOC_PROVIDER " +
")) return ");
         
@@ -246,10 +246,12 @@
             writer.write((returntypeisarray ? "RetArray" : returntypeissimple ? "Ret" : "pReturn")
+ ";\n");
         else
             writer.write(";\n");
-
+        writer.write("\n");
+        
         writer.write("\tif (NULL==axiscGetTransportPropertyCall(call,\"SOAPAction\",0))\n");
         writer.write("\t\taxiscSetTransportPropertyCall(call,AXISC_SOAPACTION_HEADER , \""
                 + minfo.getSoapAction() + "\");\n");
+        writer.write("\n");
         writer.write("\taxiscSetSOAPVersionCall(call, SOAP_VER_1_1);\n");
         //TODO check which version is it really.
         writer.write("\taxiscSetOperationCall(call, \""
@@ -261,7 +263,8 @@
         // new calls from stub base
         writer.write ("\taxiscIncludeSecure(stub);\n");  
         writer.write ("\taxiscApplyUserPreferences(stub);\n");
-          
+        writer.write("\n");
+        
         for (int i = 0; i < paramsB.size(); i++)
         {
             ParameterInfo param = (ParameterInfo) paramsB.get(i);
@@ -324,7 +327,7 @@
                 {
                     // TODO
                     String attchType = param.getType().getName().getLocalPart();
-                          writer.write("\n\tconst AxisChar *xmlSoapNsPfx" + i + 
+                    writer.write("\n\tconst AxisChar *xmlSoapNsPfx" + i + 
                         " = axiscGetNamespacePrefixCall(call,\"" + 
                         WrapperConstants.APACHE_XMLSOAP_NAMESPACE + "\");\n");
                     writer.write("\tchar attchType" + i + "[64];\n");
@@ -413,6 +416,8 @@
             if (!param.isAnyType ())
                 writer.write("\t}\n");            
           } // end for-loop
+
+        writer.write("\n");
         
         writer.write("\tif (AXISC_SUCCESS == axiscInvokeCall(call))\n\t{\n");
         writer.write("\t\tif(AXISC_SUCCESS == axiscCheckMessageCall(call, \""



Mime
View raw message