Author: nadiramra
Date: Sun May 14 01:48:17 2006
New Revision: 406283
URL: http://svn.apache.org/viewcvs?rev=406283&view=rev
Log:
C support fixes/enhancements. Testcases for C bindings.
Added:
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAll1Client.c
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAllClient.c
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAll2C.xml
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAllC.xml
Added:
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAll1Client.c
URL:
http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAll1Client.c?rev=406283&view=auto
==============================================================================
---
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAll1Client.c
(added)
+++
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAll1Client.c
Sun May 14 01:48:17 2006
@@ -0,0 +1,69 @@
+// Copyright 2003-2004 The Apache Software Foundation.
+// (c) Copyright IBM Corp. 2004, 2005 All Rights Reserved
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+
+
+
+#include <stdlib.h>
+#include <stdio.h>
+
+#include "CommonClientTestCode.h"
+#include "operations.h"
+
+#define WSDL_DEFAULT_ENDPOINT
"http://localhost:80/ComplexTypeAll/services/Service"
+
+int main(int argc, char* argv[])
+{
+
+ AXISCHANDLE ws;
+
+ aRecord input;
+ xsdc__boolean result;
+
+ xsdc__int fieldone;
+ xsdc__byte fieldthree;
+
+
+ char *endpoint = WSDL_DEFAULT_ENDPOINT;
+ int returnValue = 1; // Assume Failure
+
+
+ if(argc>2) endpoint = argv[2];
+
+ ws = get_operations_stub(endpoint);
+
+ fieldone=12345;
+ input.field1= &fieldone;
+
+ input.field2 = "I'm still here!";
+
+ fieldthree=65;
+ input.field3=&fieldthree;
+
+ result = myOperation(ws, &input);
+
+ if (result!= NULL)
+ cout, "Result= %d\n" , result );
+ else
+ printf( "result is NULL\n" );
+
+ returnValue = 0; // Success
+
+ destroy_operations_stub(ws);
+
+ printf( "---------------------- TEST COMPLETE
-----------------------------\n");
+
+ return returnValue;
+}
Added:
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAllClient.c
URL:
http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAllClient.c?rev=406283&view=auto
==============================================================================
---
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAllClient.c
(added)
+++
webservices/axis/trunk/c/tests/auto_build/testcases/client/c/ComplexTypeAllClient.c
Sun May 14 01:48:17 2006
@@ -0,0 +1,59 @@
+// Copyright 2003-2004 The Apache Software Foundation.
+// (c) Copyright IBM Corp. 2004, 2005 All Rights Reserved
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+
+
+
+#include <stdlib.h>
+#include <stdio.h>
+
+#include "CommonClientTestCode.h"
+#include "operations.h"
+
+#define WSDL_DEFAULT_ENDPOINT
"http://localhost:9080/ComplexTypeAll/services/Service"
+
+
+int main(int argc, char* argv[])
+{
+ AXISCHANDLE ws;
+
+ aRecord input;
+ xsdc__boolean result;
+
+ char *endpoint = WSDL_DEFAULT_ENDPOINT;
+ int returnValue = 1; // Assume Failure
+
+ if(argc>2) endpoint = argv[2];
+
+ ws = get_operations_stub(endpoint);
+
+ input.field1 = "Hello World!";
+ input.field2 = "I'm still here!";
+ input.field3 = "Now I go!";
+
+ result = myOperation(ws, &input);
+
+ printf( "Result %d\n" , result );
+
+ destroy_operations_stub(ws);
+
+ returnValue = 0; // Success
+
+ printf( "---------------------- TEST COMPLETE
-----------------------------\n");
+
+ return returnValue;
+}
+
+
Added:
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAll2C.xml
URL:
http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAll2C.xml?rev=406283&view=auto
==============================================================================
---
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAll2C.xml
(added)
+++
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAll2C.xml
Sun May 14 01:48:17 2006
@@ -0,0 +1,19 @@
+<test>
+ <name>ComplexTypeAll2C</name>
+ <description>ComplexTypeAll2C</description>
+ <clientLang>c</clientLang>
+ <clientCode>ComplexTypeAll2Client.c</clientCode>
+ <wsdl>ComplexTypeAll2.wsdl</wsdl>
+ <expected>
+ <output>
+ ComplexTypeAll2.cpp.out
+ </output>
+ <request>
+ ComplexTypeAll2.request
+ </request>
+ <serverResponse>
+ ComplexTypeAll2_ServerResponse.expected
+ </serverResponse>
+ </expected>
+ <endpoint>-e http://localhost:80/axis/ComplexTypeAll2</endpoint>
+</test>
Added:
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAllC.xml
URL:
http://svn.apache.org/viewcvs/webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAllC.xml?rev=406283&view=auto
==============================================================================
---
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAllC.xml
(added)
+++
webservices/axis/trunk/c/tests/auto_build/testcases/tests/ComplexTypeAllC.xml
Sun May 14 01:48:17 2006
@@ -0,0 +1,19 @@
+<test>
+ <name>ComplexTypeAllC</name>
+ <description>ComplexTypeAllC</description>
+ <clientLang>c</clientLang>
+ <clientCode>ComplexTypeAllClient.c</clientCode>
+ <wsdl>ComplexTypeAll.wsdl</wsdl>
+ <expected>
+ <output>
+ ComplexTypeAll.cpp.out
+ </output>
+ <request>
+ ComplexTypeAll.request
+ </request>
+ <serverResponse>
+ ComplexTypeAll_ServerResponse.expected
+ </serverResponse>
+ </expected>
+ <endpoint>-e http://localhost:80/axis/ComplexTypeAll</endpoint>
+</test>