You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axis-cvs@ws.apache.org by na...@apache.org on 2006/04/24 03:37:06 UTC

svn commit: r396370 - in /webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c: ArrayParamHeaderWriter.java ArrayParamWriter.java BeanParamWriter.java ClientStubWriter.java ParmHeaderFileWriter.java WrapWriter.java literal/WrapWriter.java

Author: nadiramra
Date: Sun Apr 23 18:37:04 2006
New Revision: 396370

URL: http://svn.apache.org/viewcvs?rev=396370&view=rev
Log:
C support fixes/enhancements. Put "void" in functions that do not have parameters in order to
eliminate informational messages.

Modified:
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamHeaderWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/BeanParamWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ClientStubWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParmHeaderFileWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/WrapWriter.java
    webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/WrapWriter.java

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamHeaderWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamHeaderWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamHeaderWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamHeaderWriter.java Sun Apr 23 18:37:04 2006
@@ -143,7 +143,7 @@
     {
         try
         {
-            this.writer.write("extern void* Axis_Create_" + classname + "();\n");
+            this.writer.write("extern void* Axis_Create_" + classname + "(void);\n");
         }
         catch (IOException e)
         {

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ArrayParamWriter.java Sun Apr 23 18:37:04 2006
@@ -135,7 +135,7 @@
     {
         try
         {
-            writer.write("extern void* Axis_Create_" + classname + "()\n");
+            writer.write("extern void* Axis_Create_" + classname + "(void)\n");
             writer.write("{\n");
             
             // Begin function body

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/BeanParamWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/BeanParamWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/BeanParamWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/BeanParamWriter.java Sun Apr 23 18:37:04 2006
@@ -78,7 +78,7 @@
         writer.write("/**\n");
         writer.write(" * This static method gives the size of " + classname + " type of object\n");
         writer.write(" */\n");
-        writer.write("int Axis_GetSize_" + classname + "()\n{\n\treturn sizeof(" + classname + ");\n}\n");
+        writer.write("int Axis_GetSize_" + classname + "(void)\n{\n\treturn sizeof(" + classname + ");\n}\n");
     }
 
     /**
@@ -714,7 +714,7 @@
         writer.write(" * This static method to allocate a " + classname + " type of object\n");
         writer.write(" */\n");
         
-        writer.write("void* Axis_Create_" + classname + "()\n{\n");
+        writer.write("void* Axis_Create_" + classname + "(void)\n{\n");
         
         writer.write("\t" + classname + "* pTemp = (" + classname + " *)malloc(sizeof(" + classname + "));\n");
         writer.write("\tmemset(pTemp, 0, sizeof(" + classname + "));\n");

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ClientStubWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ClientStubWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ClientStubWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ClientStubWriter.java Sun Apr 23 18:37:04 2006
@@ -620,12 +620,12 @@
                 typeName = itr.next().toString();
                 writer.write("extern int Axis_DeSerialize_" + typeName
                         + "(" + typeName  + "* param, IWrapperSoapDeSerializer* pDZ);\n");
-                writer.write("extern void* Axis_Create_" + typeName + "();\n");
+                writer.write("extern void* Axis_Create_" + typeName + "(void);\n");
                 writer.write("extern void Axis_Delete_" + typeName + "("
                         + typeName + "* param, bool bArray, int nSize);\n");
                 writer.write("extern int Axis_Serialize_" + typeName + "("
                         + typeName + "* param, IWrapperSoapSerializer* pSZ, bool bArray);\n");
-                writer.write("extern int Axis_GetSize_" + typeName + "();\n\n");
+                writer.write("extern int Axis_GetSize_" + typeName + "(void);\n\n");
             }
         }
         catch (IOException e)

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParmHeaderFileWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParmHeaderFileWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParmHeaderFileWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/ParmHeaderFileWriter.java Sun Apr 23 18:37:04 2006
@@ -74,11 +74,14 @@
             {
                 writePreprocessorStatements();
                 this.writer.write("typedef struct " + classname + "Tag {\n");
+                this.writer.write("\n");
                 writeAttributes();
+                this.writer.write("\n");
                 this.writer.write("} " + classname + ";\n\n");
                 writeFunctionPrototypes();
             }
             
+            writer.write("\n");
             this.writer.write("#endif /* !defined(__" + classname.toUpperCase() + "_H__INCLUDED_)*/\n");
             
             writer.flush();
@@ -94,112 +97,6 @@
         }
     }
 
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeAttributes()
-     */
-    protected void writeAttributes() throws WrapperFault
-    {
-        int anyCounter = 0;
-        
-        if (type.isArray())
-            return;
-        
-        try
-        {
-            if (attribs.length == 0)
-            {
-                /* TODO : needed for Aix xlc */
-                writer.write("\t int emptyStruct;\n");
-            }
-            for (int i = 0; i < attribs.length; i++)
-            {
-
-                if (isElementNillable(i) || attribs[i].isArray()) 
-                {
-                    if(attribs[i].isAnyType())
-                    {
-                        anyCounter += 1;
-                        writer.write("\t"
-                                + getCHeaderFileCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
-                                + " *  " + attribs[i].getParamName()
-                                + Integer.toString(anyCounter) + ";\n");
-                    }
-                    else
-                    {
-                        writer.write("\t"
-                                    + getCHeaderFileCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
-                                    + " *  " + attribs[i].getParamName() + ";\n");
-                    }
-                } 
-                else if(attribs[i].isAnyType())
-                {
-                    anyCounter += 1;
-                    writer.write("\t"
-                            + getCHeaderFileCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
-                            + "  " + attribs[i].getParamName()
-                            + Integer.toString(anyCounter) + ";\n");
-                }
-                else
-                {
-                    writer.write("\t"
-                                + getCHeaderFileCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
-                                + "  " + attribs[i].getParamName() + ";\n");
-                }                
-            }
-        }
-        catch (IOException e)
-        {
-            throw new WrapperFault(e);
-        }
-    }
-
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeConstructors()
-     */
-    protected void writeConstructors() throws WrapperFault
-    {}
-
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeDestructors()
-     */
-    protected void writeDestructors() throws WrapperFault
-    {}
-
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeMethods()
-     */
-    protected void writeMethods() throws WrapperFault
-    {}
-
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#getFilePath()
-     */
-    protected File getFilePath() throws WrapperFault
-    {
-        return this.getFilePath(false);
-    }
-
-    /* (non-Javadoc)
-     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#getFilePath(boolean)
-     */
-    protected File getFilePath(boolean useServiceName) throws WrapperFault
-    {
-        String targetOutputLocation = this.wscontext.getWrapInfo().getTargetOutputLocation();
-        if (targetOutputLocation.endsWith("/"))
-            targetOutputLocation = targetOutputLocation.substring(0,targetOutputLocation.length() - 1);
-        new File(targetOutputLocation).mkdirs();
-
-        String fileName = targetOutputLocation + "/" + classname + CUtils.C_HEADER_SUFFIX;
-
-        if (useServiceName)
-        {
-            fileName = targetOutputLocation + "/"
-                    + this.wscontext.getSerInfo().getServicename() + "_"
-                    + classname + CUtils.C_HEADER_SUFFIX;
-        }
-
-        return new File(fileName);
-    }
 
     /**
      * @throws WrapperFault
@@ -208,91 +105,88 @@
     {
         try
         {
+            writer.write("#include <axis/AxisUserAPI.h>\n");
+            writer.write("#include <axis/AxisUserAPIArrays.h>\n");
+            writer.write("\n");
+
             Vector restrictionData = type.getEnumerationdata();
             if (restrictionData == null)
                 return;
-            
+
             TypeEntry baseEType = (TypeEntry) restrictionData.firstElement();
             QName baseType = baseEType.getQName();
             if (!CUtils.isSimpleType(baseType))
                 return;
-            
+
             String langTypeName = CUtils.getclass4qname(baseType);
             writer.write("typedef ");
-            if ("string".equals(baseType.getLocalPart()))
+            if (CUtils.isPointerType(CUtils.getclass4qname(baseType)) 
+                    || "xsdc__base64Binary".equals(CUtils.getclass4qname(baseType)) 
+                    || "xsdc__hexBinary".equals(CUtils.getclass4qname(baseType)))
             {
                 writer.write(langTypeName + " " + classname + ";\n");
+                writer.write("typedef " + langTypeName + "_Array " + classname + "_Array;\n");
+                
                 for (int i = 1; i < restrictionData.size(); i++)
                 {
                     QName value = (QName) restrictionData.elementAt(i);
                     if ("enumeration".equals(value.getLocalPart()))
                     {
-                        writer.write(
-                            "static const " + classname + " "
-                                + classname + "_"
-                                + value.getNamespaceURI() + " = \""
-                                + value.getNamespaceURI() + "\";\n");
-                    }
+                        writer.write("static const " + classname + " "
+                                + classname + "_" + value.getNamespaceURI()
+                                + " = \"" + value.getNamespaceURI() + "\";\n");
+                    } 
                     else if ("maxLength".equals(value.getLocalPart()))
                     {
-                        writer.write(
-                            "static const " + classname + "_MaxLength = " 
-                            + value.getNamespaceURI() + ";\n");
-                    }
+                        writer.write("static const int " + classname
+                                + "_MaxLength = " + value.getNamespaceURI() + ";\n");
+                    } 
                     else if ("minLength".equals(value.getLocalPart()))
                     {
-                        writer.write(
-                            "static const " + classname + "_MinLength = " 
-                            + value.getNamespaceURI() + ";\n");
+                        writer.write("static const int " + classname
+                                + "_MinLength = " + value.getNamespaceURI() + ";\n");
                     }
                 }
-            }
+            } 
             else if ("int".equals(baseType.getLocalPart()))
             {
                 if (restrictionData.size() > 1)
-                { 
-                    //there are enumerations or [min|max]Inclusive
+                {
+                    //there are enumerations or min/maxInclusive
                     boolean isEnum = false;
                     boolean hasRestrictionItems = false;
-                    
                     for (int i = 1; i < restrictionData.size(); i++)
                     {
                         QName value = (QName) restrictionData.elementAt(i);
                         if ("enumeration".equals(value.getLocalPart()))
                         {
                             isEnum = true;
-                            
                             if (i > 1)
                                 writer.write(", ");
                             else
                                 writer.write(" enum { ");
-                            
-                            writer.write(
-                                "ENUM"
-                                    + classname.toUpperCase() + "_" + value.getNamespaceURI()
-                                    + "=" + value.getNamespaceURI());
-                        }
+
+                            writer.write("ENUM" + classname.toUpperCase() + "_"
+                                    + value.getNamespaceURI() + "="
+                                    + value.getNamespaceURI());
+                        } 
                         else if ("minInclusive".equals(value.getLocalPart()))
                         {
                             hasRestrictionItems = true;
-                            
                             if (i <= 1)
                                 writer.write(langTypeName + " " + classname + ";\n");
                             
-                            writer.write(
-                                "static const int "
-                                 + classname + "_MinInclusive = " + value.getNamespaceURI() + ";\n");
-                        }
+                            writer.write("static const int " + classname
+                                    + "_MinInclusive = " + value.getNamespaceURI() + ";\n");
+                        } 
                         else if ("maxInclusive".equals(value.getLocalPart()))
                         {
                             hasRestrictionItems = true;
-                            
                             if (i <= 1)
                                 writer.write(langTypeName + " " + classname + ";\n");
-                            
-                            writer.write(
-                                "static const int "
-                                 + classname + "_MaxInclusive = " + value.getNamespaceURI() + ";\n");
+
+                            writer.write("static const int " + classname
+                                    + "_MaxInclusive = " + value.getNamespaceURI() + ";\n");
                         }
                     }
                     
@@ -300,10 +194,10 @@
                         writer.write("} " + classname + ";\n");
                     else if (!hasRestrictionItems)
                         writer.write(langTypeName + " " + classname + ";\n");
-                }
+                } 
                 else
                     writer.write(langTypeName + " " + classname + ";\n");
-            }
+            } 
             else
             {
                 writer.write(langTypeName + " " + classname + ";\n");
@@ -312,14 +206,102 @@
                     QName value = (QName) restrictionData.elementAt(i);
                     if ("enumeration".equals(value.getLocalPart()))
                     {
+                        writer.write("static const " + classname + " "
+                                + classname + "_" + value.getNamespaceURI()
+                                + " = \"" + value.getNamespaceURI() + "\";\n");
+                    }
+                }
+            }
+        }
+        catch (IOException e)
+        {
+            throw new WrapperFault(e);
+        }
+    }
+    
+    
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeAttributes()
+     */
+    protected void writeAttributes() throws WrapperFault
+    {
+        int anyCounter = 0;
+        
+        if (type.isArray())
+            return;
+        
+        try
+        {
+            for (int i = 0; i < attribs.length; i++)
+            {
+                attribs[i].setParamName( CUtils.sanitiseAttributeName( classname, attribs[i].getParamName()));
+                
+                if (isElementNillable(i) 
+                        || attribs[i].isArray() 
+                        || isElementOptional(i) 
+                        && !attribs[i].getAllElement())
+                {
+                    if(attribs[i].isAnyType())
+                    {
+                        anyCounter += 1;
                         writer.write(
-                            "static const "
-                                + classname + " " + classname
-                                + "_" + value.getNamespaceURI()
-                                + " = " + value.getNamespaceURI() + ";\n");
+                                  getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                                + " * " + attribs[i].getParamName()
+                                + Integer.toString(anyCounter)
+                                + ";\n");
                     }
+                    else if( attribs[i].isArray())
+                    {
+                        String paramName = getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i]);
+                        if (!paramName.endsWith("*"))
+                            paramName += " *";
+
+                        writer.write(paramName + " " + attribs[i].getParamName() + ";\n");
+                    }
+                    else if(attribs[i].getChoiceElement() && !isElementNillable(i))
+                        writer.write(
+                               getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                             + " " + attribs[i].getParamName()
+                             + ";\n");
+                    else
+                        writer.write(
+                                   getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                                 + " * " + attribs[i].getParamName()
+                                 + ";\n");
+                } 
+                else if(attribs[i].getAllElement() || attribs[i].getChoiceElement() )
+                {
+                    writer.write(
+                               getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                             + " " + attribs[i].getParamName()
+                             + ";\n");
+                }
+                else if(attribs[i].isAnyType())
+                {
+                    anyCounter += 1;
+                    writer.write(
+                              getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                            + " " + attribs[i].getParamName()
+                            + Integer.toString(anyCounter)
+                            + ";\n");
+                }                   
+                else
+                {
+                    writer.write(
+                                  getCorrectParmNameConsideringArraysAndComplexTypes(attribs[i])
+                                + " " + attribs[i].getParamNameWithoutSymbols()
+                                + ";\n");
                 }
             }
+            
+            if (extensionBaseAttrib != null &&
+                getCorrectParmNameConsideringArraysAndComplexTypes(extensionBaseAttrib) != null)
+            {
+                writer.write(
+                               getCorrectParmNameConsideringArraysAndComplexTypes(extensionBaseAttrib)
+                             + " "
+                             + extensionBaseAttrib.getParamNameWithoutSymbols() + ";\n");
+            }            
         }
         catch (IOException e)
         {
@@ -327,6 +309,54 @@
         }
     }
 
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeConstructors()
+     */
+    protected void writeConstructors() throws WrapperFault
+    {}
+
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeDestructors()
+     */
+    protected void writeDestructors() throws WrapperFault
+    {}
+
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#writeMethods()
+     */
+    protected void writeMethods() throws WrapperFault
+    {}
+
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#getFilePath()
+     */
+    protected File getFilePath() throws WrapperFault
+    {
+        return this.getFilePath(false);
+    }
+
+    /* (non-Javadoc)
+     * @see org.apache.axis.wsdl.wsdl2ws.BasicFileWriter#getFilePath(boolean)
+     */
+    protected File getFilePath(boolean useServiceName) throws WrapperFault
+    {
+        String targetOutputLocation = this.wscontext.getWrapInfo().getTargetOutputLocation();
+        if (targetOutputLocation.endsWith("/"))
+            targetOutputLocation = targetOutputLocation.substring(0,targetOutputLocation.length() - 1);
+        new File(targetOutputLocation).mkdirs();
+
+        String fileName = targetOutputLocation + "/" + classname + CUtils.C_HEADER_SUFFIX;
+
+        if (useServiceName)
+        {
+            fileName = targetOutputLocation + "/"
+                    + this.wscontext.getSerInfo().getServicename() + "_"
+                    + classname + CUtils.C_HEADER_SUFFIX;
+        }
+
+        return new File(fileName);
+    }
+
     protected void writeFunctionPrototypes() throws WrapperFault
     {
         Iterator types = wscontext.getTypemap().getTypes().iterator();
@@ -358,12 +388,12 @@
                 typeName = itr.next().toString();
                 this.writer.write("extern int Axis_DeSerialize_" + typeName
                              + "(" + typeName + "* param, AXISCHANDLE pDZ);\n");
-                this.writer.write("extern void* Axis_Create_" + typeName + "();\n");
+                this.writer.write("extern void* Axis_Create_" + typeName + "(void);\n");
                 this.writer.write("extern void Axis_Delete_" + typeName
                              + "(" + typeName + "* param, AxiscBool bArray, int nSize);\n");
                 this.writer.write("extern int Axis_Serialize_" + typeName
                              + "(" + typeName + "* param, AXISCHANDLE pSZ, AxiscBool bArray);\n");
-                this.writer.write("extern int Axis_GetSize_" + typeName + "();\n\n");
+                this.writer.write("extern int Axis_GetSize_" + typeName + "(void);\n\n");
             }
         }
         catch (IOException e)
@@ -391,28 +421,18 @@
             writer.write("#include <axis/WSDDDefines.h>\n");
             writer.write("#include <axis/TypeMapping.h>\n");
 
+            if (this.type.isFault())
+                writer.write("#include <axis/SoapFaultException.h>\n");
             
-            Vector typeSet = new Vector();
-            String typeName = null;
-            
-            while (types.hasNext())
+            HashSet typeSet = new HashSet();
+            for (int i = 0; i < attribs.length; i++)
             {
-                atype = (Type) types.next();
-                if (!(atype.equals(this.type)))
-                {
-                    if (this.type.isContainedType(atype))
-                    {
-                        typeName = WrapperUtils.getLanguageTypeName4Type(atype);
-                        /* TODO : second test if for inner attributes declaration */
-                        if (null != typeName && !(typeName.charAt(0) == '>'))
-                        {
-                            if (!atype.isArray())
-                                typeSet.insertElementAt(typeName, 0);
-                            else
-                                typeSet.add(typeName);
-                        }
-                    }
-                }
+                if ((attribs[i].isArray()) && 
+                        !(attribs[i].isSimpleType() || attribs[i].getType().isSimpleType()))
+                    typeSet.add(attribs[i].getTypeName() + "_Array");
+
+                if (!(attribs[i].isSimpleType() || attribs[i].isAnyType()))
+                    typeSet.add(attribs[i].getTypeName());
             }
             
             Iterator itr = typeSet.iterator();
@@ -420,13 +440,14 @@
             {
                 writer.write("#include \"" + itr.next().toString() + CUtils.C_HEADER_SUFFIX + "\"\n");
             }
-            
+
             writer.write("\n");
+            //Local name and the URI for the type
             writer.write("/*Local name and the URI for the type*/\n");
             writer.write("static const char* Axis_URI_" + classname + " = \""
                     + type.getName().getNamespaceURI() + "\";\n");
-            writer.write("static const char* Axis_TypeName_" + classname + " = \""
-                    + type.getName().getLocalPart() + "\";\n\n");
+            writer.write("static const char* Axis_TypeName_" + classname
+                    + " = \"" + type.getName().getLocalPart() + "\";\n\n");
         }
         catch (IOException e)
         {

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/WrapWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/WrapWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/WrapWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/WrapWriter.java Sun Apr 23 18:37:04 2006
@@ -707,7 +707,7 @@
                         + typeName
                         + "* param, IWrapperSoapDeSerializer* pDZ);\n");
                 writer.write(
-                    "extern void* Axis_Create_" + typeName + "();\n");
+                    "extern void* Axis_Create_" + typeName + "(void);\n");
                 writer.write(
                     "extern void Axis_Delete_"
                         + typeName
@@ -720,7 +720,7 @@
                         + "("
                         + typeName
                         + "* param, IWrapperSoapSerializer* pSZ, bool bArray);\n");
-                writer.write("extern int Axis_GetSize_" + typeName + "();\n\n");
+                writer.write("extern int Axis_GetSize_" + typeName + "(void);\n\n");
             }
         }
         catch (IOException e)

Modified: webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/WrapWriter.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/WrapWriter.java?rev=396370&r1=396369&r2=396370&view=diff
==============================================================================
--- webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/WrapWriter.java (original)
+++ webservices/axis/trunk/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/literal/WrapWriter.java Sun Apr 23 18:37:04 2006
@@ -556,14 +556,14 @@
                     "extern int Axis_DeSerialize_" + typeName
                         + "(" + typeName + "* param, IWrapperSoapDeSerializer* pDZ);\n");
                 writer.write(
-                    "extern void* Axis_Create_" + typeName + "();\n");
+                    "extern void* Axis_Create_" + typeName + "(void);\n");
                 writer.write(
                     "extern void Axis_Delete_" + typeName
                         + "(" + typeName + "* param, bool bArray, int nSize);\n");
                 writer.write(
                     "extern int Axis_Serialize_" + typeName
                         + "(" + typeName + "* param, IWrapperSoapSerializer* pSZ, bool bArray);\n");
-                writer.write("extern int Axis_GetSize_" + typeName + "();\n\n");
+                writer.write("extern int Axis_GetSize_" + typeName + "(void);\n\n");
             }
         }
         catch (IOException e)