Enum res = tcStub->handleEnum(en);
cout << "Return value: " << res << endl;
Enum resComp = tcStub->handleEnumComplex(en, 23, 'c');
- cout << "Return value: " << resComp << endl;
+ cout << "Return value: " << resComp << endl;*/
vector<Enum> vecEn;
vecEn.push_back(APPLE);
vecEn.push_back(ORANGE);
vecEn.push_back(APPLE);
vecEn.push_back(GRAPE);
- vector<Enum> vecRes = tcStub->handleEnumArray(vecEn);
+/* vector<Enum> vecRes = tcStub->handleEnumArray(vecEn);
for (Enum en : vecRes) {
cout << "Enum value: " << en << endl;
}
}*/
-/* cout << "==== STRUCT ====" << endl;
+ cout << "==== STRUCT ====" << endl;
Struct str;
str.name = "Rahmadi";
str.value = 0.123;
str.year = 2016;
- Struct resStr = tcStub->handleStruct(str);
+/* Struct resStr = tcStub->handleStruct(str);
cout << "Name: " << resStr.name << endl;
cout << "Value:" << resStr.value << endl;
cout << "Year" << resStr.year << endl;
Struct resStr2 = tcStub->handleStructComplex(23, 'c', str);
cout << "Name: " << resStr2.name << endl;
cout << "Value:" << resStr2.value << endl;
- cout << "Year" << resStr2.year << endl;
+ cout << "Year" << resStr2.year << endl;*/
Struct str2;
str2.name = "Trimananda";
str2.value = 0.124;
vector<Struct> vecStr;
vecStr.push_back(str);
vecStr.push_back(str2);
- vector<Struct> vecRetStr = tcStub->handleStructArray(vecStr);
+/* vector<Struct> vecRetStr = tcStub->handleStructArray(vecStr);
for (Struct st : vecRetStr) {
cout << "Name: " << st.name << endl;
cout << "Value:" << st.value << endl;
cout << "Value:" << st.value << endl;
cout << "Year" << st.year << endl;
}*/
+ vector<Enum> vecRes4 = tcStub->handleEnumStruct(vecEn, vecStr, 'c');
+ for (Enum en : vecRes4) {
+ cout << "Enum value: " << en << endl;
+ }
- cout << "==== CALLBACK ====" << endl;
-/* CallBackInterface *cbSingle = new CallBack(2354);
+/* cout << "==== CALLBACK ====" << endl;
+ CallBackInterface *cbSingle = new CallBack(2354);
tcStub->registerCallback(cbSingle);
cout << "Return value from callback: " << tcStub->callBack() << endl;
CallBackInterface *cb1 = new CallBack(23);
cb.push_back(cb2);
cb.push_back(cb3);
tcStub->registerCallbackArray(cb);
- cout << "Return value from callback: " << tcStub->callBack() << endl;*/
+ cout << "Return value from callback: " << tcStub->callBack() << endl;
CallBackInterface *cb4 = new CallBack(53);
CallBackInterface *cb5 = new CallBack(63);
- CallBackInterface *cb6 = new CallBack(73);
+ CallBackInterface *cb6 = new CallBack(73);*/
vector<CallBackInterface*> cblist;
cblist.push_back(cb4);
cblist.push_back(cb5);
cblist.push_back(cb6);
// tcStub->registerCallbackList(cblist);
// cout << "Return value from callback: " << tcStub->callBack() << endl;
- tcStub->registerCallbackComplex(23, cblist, 0.1234);
- cout << "Return value from callback: " << tcStub->callBack() << endl;
+/* tcStub->registerCallbackComplex(23, cblist, 0.1234);
+ cout << "Return value from callback: " << tcStub->callBack() << endl;*/
+ vector<Enum> vecRes5 = tcStub->handleEnumStruct(vecEn, vecStr, 'c', cblist);
+ for (Enum en : vecRes5) {
+ cout << "Enum value: " << en << endl;
+ }
return 0;
}