Completing stub and skeleton sides' APIs; Adding tests for C++ side; Still need to...
[iot2.git] / iotjava / iotrmi / C++ / sample / TestClass.cpp
diff --git a/iotjava/iotrmi/C++/sample/TestClass.cpp b/iotjava/iotrmi/C++/sample/TestClass.cpp
new file mode 100644 (file)
index 0000000..b70d237
--- /dev/null
@@ -0,0 +1,23 @@
+#include <iostream>
+#include <string>
+#include "TestClass.hpp"
+
+using namespace std;
+
+int main(int argc, char *argv[])
+{
+
+       TestClassInterface *tc = new TestClass();
+       cout << "Return value: " << tc->setAndGetA(123) << endl;
+       cout << "Return value: " << tc->setACAndGetA("string", 123) << endl;
+       vector<string> input;
+       input.push_back("123");
+       input.push_back("456");
+       input.push_back("987");
+
+       cout << "Return value: " << tc->sumArray(input) << endl;
+
+       delete tc;
+
+       return 0;
+}