axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From whitl...@apache.org
Subject cvs commit: ws-axis/c/tools/org/apache/axis/tools/cbindings CBindingGenerator.java
Date Wed, 19 Jan 2005 10:55:16 GMT
whitlock    2005/01/19 02:55:16

  Modified:    c/build  buildTools.xml
               c/include/axis AxisUserAPI.h
               c/src/cbindings AxisC.cpp AxisExceptionC.cpp BasicNodeC.cpp
               c/tools/org/apache/axis/tools/cbindings
                        CBindingGenerator.java
  Log:
  More C bindings: add Stub
  
  Revision  Changes    Path
  1.6       +2 -2      ws-axis/c/build/buildTools.xml
  
  Index: buildTools.xml
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/build/buildTools.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- buildTools.xml	13 Jan 2005 16:32:01 -0000	1.5
  +++ buildTools.xml	19 Jan 2005 10:55:16 -0000	1.6
  @@ -102,7 +102,7 @@
   					<libset dir="${dir.bin}" libs="${clientLibraryName}" unless="os400"/>
   					<!-- Files to be compiled -->
   					<fileset dir="${dir.src}">
  -						<include name="cbindings/*.cpp"/>
  +						<include name="cbindings/**"/>
   					</fileset>
   				</cc>
   			</then>
  @@ -123,7 +123,7 @@
   					<libset dir="${dir.bin}" libs="${clientLibraryName}"/>
   					<!-- Files to be compiled -->
   					<fileset dir="${dir.src}">
  -						<include name="cbindings/*.cpp"/>
  +						<include name="cbindings/**"/>
   					</fileset>
   				</cc>
   			</else>
  
  
  
  1.2       +74 -74    ws-axis/c/include/axis/AxisUserAPI.h
  
  Index: AxisUserAPI.h
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/include/axis/AxisUserAPI.h,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AxisUserAPI.h	7 Jan 2005 16:35:20 -0000	1.1
  +++ AxisUserAPI.h	19 Jan 2005 10:55:16 -0000	1.2
  @@ -28,152 +28,152 @@
     */
   
   /**
  - * @typedef xsd__string
  + * @typedef xsdc__string
    * Axis C++ defined type for xml basic type string
    */
  -typedef AxiscChar * xsd__string;
  +typedef AxiscChar * xsdc__string;
   
   /**
  - * @typedef xsd__integer
  + * @typedef xsdc__integer
    * Axis C++ defined type for xml basic type integer
    */
  -typedef int xsd__integer;
  +typedef int xsdc__integer;
   
   /**
  - * @typedef xsd__int
  + * @typedef xsdc__int
    * Axis C++ defined type for xml basic type int
    */
  -typedef int xsd__int;
  +typedef int xsdc__int;
   
   /**
  - * @typedef xsd__long
  + * @typedef xsdc__long
    * Axis C++ defined type for xml basic type long
    */
   #ifdef WIN32
  -typedef __int64 xsd__long;
  +typedef __int64 xsdc__long;
   #else
  -typedef long long xsd__long;
  +typedef long long xsdc__long;
   #endif
   
   /**
  - * @typedef xsd__short
  + * @typedef xsdc__short
    * Axis C++ defined type for xml basic type short
    */
  -typedef short xsd__short;
  +typedef short xsdc__short;
   
   /**
  - * @typedef xsd__decimal
  + * @typedef xsdc__decimal
    * Axis C++ defined type for xml basic type decimal
    */
  -typedef double xsd__decimal;
  +typedef double xsdc__decimal;
   
   /**
  - * @typedef xsd__float
  + * @typedef xsdc__float
    * Axis C++ defined type for xml basic type float
    */
  -typedef float xsd__float;
  +typedef float xsdc__float;
   
   /**
  - * @typedef xsd__double
  + * @typedef xsdc__double
    * Axis C++ defined type for xml basic type double
    */
  -typedef double xsd__double;
  +typedef double xsdc__double;
   
   /**
  - * @typedef xsd__boolean
  + * @typedef xsdc__boolean
    * Axis C++ defined type for xml basic type boolean
    */
  -typedef enum { false_=0, true_ } xsd__boolean;
  +typedef enum { false_=0, true_ } xsdc__boolean;
   
   /**
  - * @typedef xsd__byte
  + * @typedef xsdc__byte
    * Axis C++ defined type for xml basic type byte
    */
  -typedef signed char xsd__byte;
  +typedef signed char xsdc__byte;
   
   /**
  - * @typedef xsd__QName
  + * @typedef xsdc__QName
    * Axis C++ defined type for xml basic type QName
    */
  -typedef AxiscChar * xsd__QName;
  +typedef AxiscChar * xsdc__QName;
   
   /**
  - * @typedef xsd__NCName
  + * @typedef xsdc__NCName
    * Axis C++ defined type for xml basic type NCName
    */
  -typedef AxiscChar * xsd__NCName;
  +typedef AxiscChar * xsdc__NCName;
   
   /**
  - * @typedef xsd__dateTime
  + * @typedef xsdc__dateTime
    * Axis C++ defined type for xml basic type dateTime
    */
  -typedef struct tm xsd__dateTime;
  +typedef struct tm xsdc__dateTime;
   
   /**
  - * @typedef xsd__date
  + * @typedef xsdc__date
    * Axis C++ defined type for xml basic type date
    */
  -typedef struct tm xsd__date;
  +typedef struct tm xsdc__date;
   
   /**
  - * @typedef xsd__time
  + * @typedef xsdc__time
    * Axis C++ defined type for xml basic type time
    */
  -typedef struct tm xsd__time;
  +typedef struct tm xsdc__time;
   
   /**
  - * @typedef xsd__unsignedByte
  + * @typedef xsdc__unsignedByte
    * Axis C++ defined type for xml basic type unsignedByte
    */
  -typedef unsigned char xsd__unsignedByte;
  +typedef unsigned char xsdc__unsignedByte;
   
   /**
  - * @typedef xsd__unsignedInt
  + * @typedef xsdc__unsignedInt
    * Axis C++ defined type for xml basic type unsignedInt
    */
  -typedef unsigned int xsd__unsignedInt;
  +typedef unsigned int xsdc__unsignedInt;
   
   /**
  - * @typedef xsd__unsignedLong
  + * @typedef xsdc__unsignedLong
    * Axis C++ defined type for xml basic type unsignedLong
    */
  -typedef unsigned long xsd__unsignedLong;
  +typedef unsigned long xsdc__unsignedLong;
   
   /**
  - * @typedef xsd__unsignedShort
  + * @typedef xsdc__unsignedShort
    * Axis C++ defined type for xml basic type unsignedShort
    */
  -typedef unsigned short xsd__unsignedShort;
  +typedef unsigned short xsdc__unsignedShort;
   
   /**
  - * @struct xsd__base64Binary
  + * @struct xsdc__base64Binary
    * Axis C++ defined type for xml basic type base64Binary
    */
   typedef struct {
  -    xsd__unsignedByte * __ptr;
  -    xsd__int __size;
  -} xsd__base64Binary;
  +    xsdc__unsignedByte * __ptr;
  +    xsdc__int __size;
  +} xsdc__base64Binary;
   
   /**
  - * @struct xsd__hexBinary
  + * @struct xsdc__hexBinary
    * Axis C++ defined type for xml basic type hexBinary
    */
   typedef struct {
  -    xsd__unsignedByte * __ptr;
  -    xsd__int __size;
  -} xsd__hexBinary;
  +    xsdc__unsignedByte * __ptr;
  +    xsdc__int __size;
  +} xsdc__hexBinary;
   
   /**
  - * @typedef xsd__anyURI
  + * @typedef xsdc__anyURI
    * Axis C++ defined type for xml basic type anyURI
    */
  -typedef AxiscChar * xsd__anyURI;
  +typedef AxiscChar * xsdc__anyURI;
   
   /**
  - * @typedef xsd__NMTOKEN
  + * @typedef xsdc__NMTOKEN
    * Axis C++ defined type for xml basic type anyURI
    */
  -typedef AxiscChar * xsd__NMTOKEN;
  +typedef AxiscChar * xsdc__NMTOKEN;
   
   /**
    * @enum AXISC_BINDING_STYLE
  @@ -203,26 +203,26 @@
       int m_Size;
   } Axisc_Array;
   
  -AXISC_DEFINED_ARRAY(xsd__string)
  -AXISC_DEFINED_ARRAY(xsd__integer)
  -AXISC_DEFINED_ARRAY(xsd__int)
  -AXISC_DEFINED_ARRAY(xsd__long)
  -AXISC_DEFINED_ARRAY(xsd__short)
  -AXISC_DEFINED_ARRAY(xsd__decimal)
  -AXISC_DEFINED_ARRAY(xsd__float)
  -AXISC_DEFINED_ARRAY(xsd__double)
  -AXISC_DEFINED_ARRAY(xsd__boolean)
  -AXISC_DEFINED_ARRAY(xsd__QName)
  -AXISC_DEFINED_ARRAY(xsd__NCName)
  -AXISC_DEFINED_ARRAY(xsd__dateTime)
  -AXISC_DEFINED_ARRAY(xsd__unsignedByte)
  -AXISC_DEFINED_ARRAY(xsd__unsignedInt)
  -AXISC_DEFINED_ARRAY(xsd__unsignedLong)
  -AXISC_DEFINED_ARRAY(xsd__unsignedShort)
  -AXISC_DEFINED_ARRAY2(xsd__base64Binary)
  -AXISC_DEFINED_ARRAY2(xsd__hexBinary)
  -AXISC_DEFINED_ARRAY(xsd__anyURI)
  -AXISC_DEFINED_ARRAY(xsd__NMTOKEN)
  +AXISC_DEFINED_ARRAY(xsdc__string)
  +AXISC_DEFINED_ARRAY(xsdc__integer)
  +AXISC_DEFINED_ARRAY(xsdc__int)
  +AXISC_DEFINED_ARRAY(xsdc__long)
  +AXISC_DEFINED_ARRAY(xsdc__short)
  +AXISC_DEFINED_ARRAY(xsdc__decimal)
  +AXISC_DEFINED_ARRAY(xsdc__float)
  +AXISC_DEFINED_ARRAY(xsdc__double)
  +AXISC_DEFINED_ARRAY(xsdc__boolean)
  +AXISC_DEFINED_ARRAY(xsdc__QName)
  +AXISC_DEFINED_ARRAY(xsdc__NCName)
  +AXISC_DEFINED_ARRAY(xsdc__dateTime)
  +AXISC_DEFINED_ARRAY(xsdc__unsignedByte)
  +AXISC_DEFINED_ARRAY(xsdc__unsignedInt)
  +AXISC_DEFINED_ARRAY(xsdc__unsignedLong)
  +AXISC_DEFINED_ARRAY(xsdc__unsignedShort)
  +AXISC_DEFINED_ARRAY2(xsdc__base64Binary)
  +AXISC_DEFINED_ARRAY2(xsdc__hexBinary)
  +AXISC_DEFINED_ARRAY(xsdc__anyURI)
  +AXISC_DEFINED_ARRAY(xsdc__NMTOKEN)
    
   static const int xsd_boolean_true = 1;
   static const int xsd_boolean_false = 0;
  @@ -233,10 +233,10 @@
   } AXISC_CHANNEL_TYPE;
   
   /**
  - * @typedef XML_String
  + * @typedef AXISC_XML_String
    * Axis C++ defined type for xml encoded string. This is used only in AnyType.
    */
  -typedef char* XML_String;
  +typedef char* AXISC_XML_String;
   
   /**
    * @struct AxiscAnyType
  @@ -247,7 +247,7 @@
       /**
        * @var _array Contains an array of xml encoded strings.
        */
  -    XML_String* _array;
  +    AXISC_XML_String* _array;
   
       /**
        * @var _size Contains how many xml strings are there in _array
  
  
  
  1.3       +2 -0      ws-axis/c/src/cbindings/AxisC.cpp
  
  Index: AxisC.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/cbindings/AxisC.cpp,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- AxisC.cpp	14 Jan 2005 13:55:30 -0000	1.2
  +++ AxisC.cpp	19 Jan 2005 10:55:16 -0000	1.3
  @@ -18,6 +18,8 @@
   AXIS_CPP_NAMESPACE_USE
   
   extern "C" {
  +#include <axis/GDefine.h>
  +#include <axis/AxisUserAPI.h>
   #include <axis/Axis.h>
   
   STORAGE_CLASS_INFO void axiscInitializeAxis(AxiscBool bIsServer) {
  
  
  
  1.2       +2 -0      ws-axis/c/src/cbindings/AxisExceptionC.cpp
  
  Index: AxisExceptionC.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/cbindings/AxisExceptionC.cpp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- AxisExceptionC.cpp	14 Jan 2005 17:29:52 -0000	1.1
  +++ AxisExceptionC.cpp	19 Jan 2005 10:55:16 -0000	1.2
  @@ -17,6 +17,8 @@
   AXIS_CPP_NAMESPACE_USE
   
   extern "C" {
  +#include <axis/GDefine.h>
  +#include <axis/AxisUserAPI.h>
   #include <axis/AxisException.h>
   
   AXISC_STORAGE_CLASS_INFO void axiscDestroyAxisException(AXISCHANDLE axisException) {
  
  
  
  1.2       +2 -0      ws-axis/c/src/cbindings/BasicNodeC.cpp
  
  Index: BasicNodeC.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/cbindings/BasicNodeC.cpp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BasicNodeC.cpp	14 Jan 2005 17:29:52 -0000	1.1
  +++ BasicNodeC.cpp	19 Jan 2005 10:55:16 -0000	1.2
  @@ -17,6 +17,8 @@
   AXIS_CPP_NAMESPACE_USE
   
   extern "C" {
  +#include <axis/GDefine.h>
  +#include <axis/AxisUserAPI.h>
   #include <axis/BasicNode.h>
   
   AXISC_STORAGE_CLASS_INFO AXISCHANDLE axiscGetAttribute(AXISCHANDLE basicNode, AxiscChar
* pachPrefix, 
  
  
  
  1.8       +11 -2     ws-axis/c/tools/org/apache/axis/tools/cbindings/CBindingGenerator.java
  
  Index: CBindingGenerator.java
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/tools/org/apache/axis/tools/cbindings/CBindingGenerator.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- CBindingGenerator.java	17 Jan 2005 12:39:16 -0000	1.7
  +++ CBindingGenerator.java	19 Jan 2005 10:55:16 -0000	1.8
  @@ -188,11 +188,13 @@
   				// Putting #includes of GDefine and AxisUserAPI in <> not "" is needed for the
   				// ant build because those 2 headers aren't generated.
   				text = replaceInString(text,"\"GDefine.hpp\"","<axis/GDefine.hpp>",null);
  +				text = replaceInString(text,"\"../GDefine.hpp\"","<axis/GDefine.hpp>",null);
   				text = replaceInString(text,"\"AxisUserAPI.hpp\"","<axis/AxisUserAPI.hpp>",null);
  +				text = replaceInString(text,"\"../AxisUserAPI.hpp\"","<axis/AxisUserAPI.hpp>",null);
   				text = replaceInString(text,".hpp",".h",null);
   			}
  -			outputFile.write(text);
  -			outputFile.newLine();
  +			//outputFile.write(text); Remove all #include's
  +			//outputFile.newLine();
   		} else if (
   		    // In AxisUserAPI.h we must keep a #ifdef WIN32/#else/#endif
   			keepIfdef
  @@ -339,6 +341,9 @@
   	private static String classNamePretty(String className) {
   		if (className == null)
   			return null;
  +		// namespace is a reserved word so make sure we never return namespace
  +		if (className.equals("INamespace"))
  +			return className;
   		if (className.startsWith("I"))
   			return className.substring(1);
   		return className;
  @@ -372,6 +377,10 @@
   				type += "AxiscAnyType";
   			} else if ("bool".equals(tok)) {
   				type += "AxiscBool";
  +			} else if ("XML_String".equals(tok)) {
  +				type += "AXISC_XML_String";
  +			} else if (tok.startsWith("xsd__")) {
  +				type += replaceInString(tok,"xsd__","xsdc__",null);
   			} else if (-1 != tok.toLowerCase().indexOf("axis")) {
   				type += changeAxisToAxisc(tok);
   			} else if (!Utils.cTypeQualifiers.contains(tok) && 
  
  
  

Mime
View raw message