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/tests/auto_build/testcases/output DynamicAttachmentRequest.out
Date Tue, 21 Jun 2005 15:45:26 GMT
whitlock    2005/06/21 08:45:26

  Modified:    c/src/soap SoapAttachment.cpp
               c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/cpp/literal
                        ClientStubWriter.java
               c/tests/auto_build/testcases/output
                        DynamicAttachmentRequest.out
  Log:
  Attachments: Add in support in WSDL2Ws for attributes on attachment references in the SOAP
body
  
  Revision  Changes    Path
  1.15      +1 -0      ws-axis/c/src/soap/SoapAttachment.cpp
  
  Index: SoapAttachment.cpp
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/soap/SoapAttachment.cpp,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- SoapAttachment.cpp	20 Jun 2005 16:23:00 -0000	1.14
  +++ SoapAttachment.cpp	21 Jun 2005 15:45:26 -0000	1.15
  @@ -155,6 +155,7 @@
   	list<Attribute*>::iterator it = m_attributes.begin();
   	while (it != m_attributes.end())
   	{
  +		pSZ.serialize("\n  ",NULL);
   		(*it)->serialize(pSZ);
   		it++;
   	}
  
  
  
  1.93      +15 -1     ws-axis/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/cpp/literal/ClientStubWriter.java
  
  Index: ClientStubWriter.java
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/src/wsdl/org/apache/axis/wsdl/wsdl2ws/cpp/literal/ClientStubWriter.java,v
  retrieving revision 1.92
  retrieving revision 1.93
  diff -u -r1.92 -r1.93
  --- ClientStubWriter.java	21 Jun 2005 14:14:13 -0000	1.92
  +++ ClientStubWriter.java	21 Jun 2005 15:45:26 -0000	1.93
  @@ -36,6 +36,7 @@
   import javax.xml.namespace.QName;
   
   import org.apache.axis.wsdl.wsdl2ws.CUtils;
  +import org.apache.axis.wsdl.wsdl2ws.WrapperConstants;
   import org.apache.axis.wsdl.wsdl2ws.WrapperFault;
   import org.apache.axis.wsdl.wsdl2ws.WrapperUtils;
   import org.apache.axis.wsdl.wsdl2ws.info.FaultInfo;
  @@ -628,7 +629,20 @@
   
   		    if (param.getType().isAttachment())
   		    {
  -			writer.write ("\tm_pCall->addAttachmentParameter(Value" + i + ", cPrefixAndParamName"
+ i);
  +			String attchType = param.getType().getName().getLocalPart();
  +                  writer.write("\n\tconst AxisChar *xmlSoapNsPfx" + i + 
  +				" = m_pCall->getNamespacePrefix(\"" + 
  +				WrapperConstants.APACHE_XMLSOAP_NAMESPACE + "\");\n");
  +			writer.write("\tchar attchType" + i + "[64];\n");
  +			writer.write("\tstrcpy(attchType" + i + ", xmlSoapNsPfx" + i + ");\n");
  +			writer.write("\tstrcat(attchType" + i + ", \":" + attchType + "\");\n");
  +			writer.write("\tIAttribute *attrs" + i + "[2];\n");
  +			writer.write("\tattrs" + i + "[0] = m_pCall->createAttribute(\"type\", \"xsi\", attchType"
+ i + 
  +				");\n");
  +			writer.write("\tattrs" + i + "[1] = m_pCall->createAttribute(xmlSoapNsPfx" + i +

  +				", \"xmlns\", \"http://xml.apache.org/xml-soap\");\n");
  +			writer.write("\tm_pCall->addAttachmentParameter(Value" + i + ", cPrefixAndParamName"
+ i + 
  +				", attrs" + i + ", 2");
   		    }
   		    else if (typeisarray)
   		    {
  
  
  
  1.4       +4 -2      ws-axis/c/tests/auto_build/testcases/output/DynamicAttachmentRequest.out
  
  Index: DynamicAttachmentRequest.out
  ===================================================================
  RCS file: /home/cvs/ws-axis/c/tests/auto_build/testcases/output/DynamicAttachmentRequest.out,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- DynamicAttachmentRequest.out	20 Jun 2005 16:23:01 -0000	1.3
  +++ DynamicAttachmentRequest.out	21 Jun 2005 15:45:26 -0000	1.4
  @@ -2,7 +2,7 @@
   Host: localhost:13260
   SOAPAction: "Trash"
   Content-Type: multipart/related; type="text/xml"; boundary="------=MIME_BOUNDARY"; start="<5>"
  -Content-Length: 1396
  +Content-Length: 1402
   
   
   --------=MIME_BOUNDARY
  @@ -16,7 +16,9 @@
   <ns1:put xmlns:ns1="http://localhost/axis/DynamicAttachment">
   <arg_attachment_1 href="cid:1"/>
   <arg_attachment_2 href="cid:12"/>
  -<arg_attachment_3 href="cid:3" mypfx1:myname1="http://dynamicattachment/test.axis.apache.org"
xsi:myname2="myvalue2"/>
  +<arg_attachment_3 href="cid:3"
  +   mypfx1:myname1="http://dynamicattachment/test.axis.apache.org"
  +   xsi:myname2="myvalue2"/>
   </ns1:put>
   </SOAP-ENV:Body>
   </SOAP-ENV:Envelope>
  
  
  

Mime
View raw message