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 wh...@apache.org on 2005/01/26 12:10:08 UTC

cvs commit: ws-axis/c/tools/org/apache/axis/tools/cbindings CBindingGenerator.java cbindinggenerator.conf

whitlock    2005/01/26 03:10:08

  Modified:    c/include/axis IWrapperSoapSerializer.hpp
               c/src/cbindings IWrapperSoapSerializerC.cpp
               c/src/soap SoapSerializer.cpp SoapSerializer.h
               c/tools/org/apache/axis/tools/cbindings
                        CBindingGenerator.java cbindinggenerator.conf
  Log:
  Get C bindings for IWrapperSoapSerializer working
  
  Revision  Changes    Path
  1.4       +3 -0      ws-axis/c/include/axis/IWrapperSoapSerializer.hpp
  
  Index: IWrapperSoapSerializer.hpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/include/axis/IWrapperSoapSerializer.hpp,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- IWrapperSoapSerializer.hpp	7 Jan 2005 08:55:19 -0000	1.3
  +++ IWrapperSoapSerializer.hpp	26 Jan 2005 11:10:07 -0000	1.4
  @@ -21,6 +21,8 @@
   #include "TypeMapping.hpp"
   #include "WSDDDefines.hpp"
   #include "ISoapAttachment.hpp"
  +#include <stdarg.h>
  +#include <cctype>
   
   /*
    *  @class IWrapperSoapSerializer
  @@ -96,6 +98,7 @@
       virtual int AXISCALL serializeAsAttribute(const AxisChar* sName, 
           const AxisChar* pNamespace, void* pValue, XSDTYPE type)=0;
   
  +    virtual void AXISCALL serializeVargs(const char* pFirst, va_list vargs)=0;
       virtual void AXISCALL serialize(const char* pFirst, ...)=0;
   
       /* 
  
  
  
  1.2       +9 -0      ws-axis/c/src/cbindings/IWrapperSoapSerializerC.cpp
  
  Index: IWrapperSoapSerializerC.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/cbindings/IWrapperSoapSerializerC.cpp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- IWrapperSoapSerializerC.cpp	25 Jan 2005 14:21:46 -0000	1.1
  +++ IWrapperSoapSerializerC.cpp	26 Jan 2005 11:10:07 -0000	1.2
  @@ -15,6 +15,7 @@
    */
   
   #include <axis/IWrapperSoapSerializer.hpp>
  +#include "../soap/SoapSerializer.h"
   AXIS_CPP_NAMESPACE_USE
   
   extern "C" {
  @@ -173,4 +174,12 @@
   	return (AXISCHANDLE)(sz->createSoapAttachement());
   }
   
  +AXISC_STORAGE_CLASS_INFO void axiscSerialize(AXISCHANDLE wrapperSoapSerializer, const char *pFirst, ...) {
  +	SoapSerializer *sz = (SoapSerializer*)wrapperSoapSerializer;
  +	va_list vList;
  +	va_start( vList, pFirst );
  +	sz->serializeVargs(pFirst,vList);
  +	va_end( vList);
  +}
  +
   }
  
  
  
  1.88      +8 -3      ws-axis/c/src/soap/SoapSerializer.cpp
  
  Index: SoapSerializer.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/soap/SoapSerializer.cpp,v
  retrieving revision 1.87
  retrieving revision 1.88
  diff -u -r1.87 -r1.88
  --- SoapSerializer.cpp	21 Jan 2005 12:26:14 -0000	1.87
  +++ SoapSerializer.cpp	26 Jan 2005 11:10:07 -0000	1.88
  @@ -702,12 +702,10 @@
       }
   }
   
  -void SoapSerializer::serialize(const char* pFirst, ...)
  +void SoapSerializer::serializeVargs(const char* pFirst, va_list vList)
   {
  -    va_list vList;
       const char* pArg;
       if (pFirst) *this << pFirst;
  -    va_start( vList, pFirst );     /* Initialize variable arguments. */
       do
       {
           pArg = va_arg( vList, const char*);
  @@ -715,6 +713,13 @@
               *this << pArg;
       }
       while (pArg != NULL);
  +}
  +
  +void SoapSerializer::serialize(const char* pFirst, ...)
  +{
  +    va_list vList;
  +    va_start( vList, pFirst );     /* Initialize variable arguments. */
  +    serializeVargs(pFirst,vList);
       va_end( vList);              /* Reset variable arguments.      */
   }
   
  
  
  
  1.38      +3 -0      ws-axis/c/src/soap/SoapSerializer.h
  
  Index: SoapSerializer.h
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/soap/SoapSerializer.h,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -r1.37 -r1.38
  --- SoapSerializer.h	21 Jan 2005 12:26:14 -0000	1.37
  +++ SoapSerializer.h	26 Jan 2005 11:10:08 -0000	1.38
  @@ -23,6 +23,8 @@
   #include "../common/BasicTypeSerializer.h"
   #include <axis/WSDDDefines.hpp>
   #include "SoapAttachment.hpp"
  +#include <stdarg.h>
  +#include <cctype>
   
   AXIS_CPP_NAMESPACE_START
   
  @@ -185,6 +187,7 @@
           void* pValue, XSDTYPE type);
       int AXISCALL serializeAsAttribute(const AxisChar* pName, 
           const AxisChar* pNamespace, void* pValue, XSDTYPE type);
  +    void AXISCALL serializeVargs(const char* pFirst, va_list vargs);
       void AXISCALL serialize(const char* pFirst, ...);
       void setStyle(AXIS_BINDING_STYLE nStyle)
       { m_nStyle = nStyle; m_BTSZ.setStyle(nStyle);};
  
  
  
  1.10      +2 -0      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.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- CBindingGenerator.java	20 Jan 2005 11:23:18 -0000	1.9
  +++ CBindingGenerator.java	26 Jan 2005 11:10:08 -0000	1.10
  @@ -387,6 +387,8 @@
   			} else if (!Utils.cTypeQualifiers.contains(tok) && 
   				!Utils.cPrimitives.contains(tok) && 
   				!tok.equals("tm") && 		// Leave struct tm alone
  +				!tok.equals("...") && 		// Leave ... alone
  +				!tok.equals("va_list") && 	// Leave ... alone
   				!tok.startsWith("xsd")) {
   				type += "AXISC_"+tok;
   			} else {
  
  
  
  1.7       +0 -1      ws-axis/c/tools/org/apache/axis/tools/cbindings/cbindinggenerator.conf
  
  Index: cbindinggenerator.conf
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/tools/org/apache/axis/tools/cbindings/cbindinggenerator.conf,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- cbindinggenerator.conf	25 Jan 2005 14:21:46 -0000	1.6
  +++ cbindinggenerator.conf	26 Jan 2005 11:10:08 -0000	1.7
  @@ -39,7 +39,6 @@
   excludemethod=IMessageData::getService
   excludemethod=BasicNode::BasicNode
   excludemethod=IHeaderBlock::IHeaderBlock
  -excludemethod=IWrapperSoapSerializer::serialize