You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by wh...@apache.org on 2005/07/07 18:29:01 UTC
cvs commit: ws-axis/c/tests/auto_build/testcases/output DynamicSetSOAPMethodAttrTest1Request.out
whitlock 2005/07/07 09:29:01
Modified: c/src/engine/client Call.cpp
c/src/soap Attribute.cpp SoapSerializer.cpp
c/tests/auto_build/testcases/dynamic/DynamicSetSOAPMethodAttrTest1
Calculator.cpp
c/tests/auto_build/testcases/output
DynamicSetSOAPMethodAttrTest1Request.out
Log:
AXISCPP-704 Make DynamicSetSOAPMethodAttrTest1 work. Add in checks for NULL.
Revision Changes Path
1.121 +1 -0 ws-axis/c/src/engine/client/Call.cpp
Index: Call.cpp
===================================================================
RCS file: /home/cvs/ws-axis/c/src/engine/client/Call.cpp,v
retrieving revision 1.120
retrieving revision 1.121
diff -u -r1.120 -r1.121
--- Call.cpp 6 Jul 2005 18:00:31 -0000 1.120
+++ Call.cpp 7 Jul 2005 16:29:01 -0000 1.121
@@ -1038,6 +1038,7 @@
const AxisChar *pUri, const AxisChar *pValue)
{
IAttribute* pAttribute;
+ if (pValue==NULL) pValue = "";
if (NULL!=pUri)
{
std::list<Attribute*> attributeList;
1.40 +8 -2 ws-axis/c/src/soap/Attribute.cpp
Index: Attribute.cpp
===================================================================
RCS file: /home/cvs/ws-axis/c/src/soap/Attribute.cpp,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -r1.39 -r1.40
--- Attribute.cpp 8 Jun 2005 10:23:01 -0000 1.39
+++ Attribute.cpp 7 Jul 2005 16:29:01 -0000 1.40
@@ -185,7 +185,10 @@
m_localname= localname;
m_prefix= prefix;
m_uri= uri;
- m_value= value;
+ if (NULL==value)
+ m_value = "";
+ else
+ m_value= value;
if( (void *) &attribute != NULL && !attribute.empty())
{
@@ -211,7 +214,10 @@
m_localname= localname;
m_prefix= prefix;
m_uri= "";
- m_value= value;
+ if (NULL==value)
+ m_value = "";
+ else
+ m_value= value;
if( (void *) &attribute != NULL && !attribute.empty())
{
1.131 +2 -0 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.130
retrieving revision 1.131
diff -u -r1.130 -r1.131
--- SoapSerializer.cpp 30 Jun 2005 11:19:01 -0000 1.130
+++ SoapSerializer.cpp 7 Jul 2005 16:29:01 -0000 1.131
@@ -1290,6 +1290,8 @@
}
}
+ if (NULL==m_pSoapEnvelope->m_pSoapHeader) return "";
+
// Couldn't find the namespace in the namespace list. Try trawling through the
// SOAP headers looking to see if any of their children have defined any
// namespaces.
1.2 +3 -3 ws-axis/c/tests/auto_build/testcases/dynamic/DynamicSetSOAPMethodAttrTest1/Calculator.cpp
Index: Calculator.cpp
===================================================================
RCS file: /home/cvs/ws-axis/c/tests/auto_build/testcases/dynamic/DynamicSetSOAPMethodAttrTest1/Calculator.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- Calculator.cpp 21 Jun 2005 14:23:13 -0000 1.1
+++ Calculator.cpp 7 Jul 2005 16:29:01 -0000 1.2
@@ -66,18 +66,18 @@
m_pCall->setSOAPMethodAttribute("Name","ns1","Axis");
/* Checking whether API creates duplicate Attribute. An element cannot have two attributes with same name */
- m_pCall->setSOAPMethodAttribute("Name","ns1","Hello");
+ // m_pCall->setSOAPMethodAttribute("Name","ns1","Hello");
/* Adding another SOAP Method Attribute - 'Type' without a prefix */
m_pCall->setSOAPMethodAttribute("Type","","Open Source");
/* Testing behaviour with NULL Values*/
- //m_pCall->setSOAPMethodAttribute("NULLTest","ns1",NULL);
+ m_pCall->setSOAPMethodAttribute("NULLTest","ns1",NULL);
/* Passing an undeclared namespace prefix as argument */
- //m_pCall->setSOAPMethodAttribute("Test","ns10","","Undefined Prefix");
+ m_pCall->setSOAPMethodAttribute("Test","ns10","","Undefined Prefix");
1.2 +2 -2 ws-axis/c/tests/auto_build/testcases/output/DynamicSetSOAPMethodAttrTest1Request.out
Index: DynamicSetSOAPMethodAttrTest1Request.out
===================================================================
RCS file: /home/cvs/ws-axis/c/tests/auto_build/testcases/output/DynamicSetSOAPMethodAttrTest1Request.out,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- DynamicSetSOAPMethodAttrTest1Request.out 21 Jun 2005 14:19:45 -0000 1.1
+++ DynamicSetSOAPMethodAttrTest1Request.out 7 Jul 2005 16:29:01 -0000 1.2
@@ -2,12 +2,12 @@
Host: localhost:13260
Content-Type: text/xml; charset=UTF-8
SOAPAction: "Calculator#div"
-Content-Length: 435
+Content-Length: 451
<?xml version='1.0' encoding='utf-8' ?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<SOAP-ENV:Body>
-<ns1:div xmlns:ns1="http://localhost/axis/Calculator" ns1:Name="Axis" Type="Open Source">
+<ns1:div xmlns:ns1="http://localhost/axis/Calculator" ns1:Name="Axis" Type="Open Source" ns1:NULLTest="">
<ns1:arg_0_3>100</ns1:arg_0_3>
<ns1:arg_1_3>20</ns1:arg_1_3>
</ns1:div>