using namespace std;
LightBulb_Skeleton::LightBulb_Skeleton(LightBulb *_mainObj, int _portSend, int _portRecv) {
+
bool _bResult = false;
mainObj = _mainObj;
rmiComm = new IoTRMICommServer(_portSend, _portRecv, &_bResult);
}
switch (methodId) {
case 0: {
- thread th0 (&LightBulb_Skeleton::___init, std::ref(skel), skel);
+ thread th0 (&LightBulb_Skeleton::___init, skel, skel);
th0.detach(); break;
}
case 1: {
- thread th1 (&LightBulb_Skeleton::___turnOff, std::ref(skel), skel);
+ thread th1 (&LightBulb_Skeleton::___turnOff, skel, skel);
th1.detach(); break;
}
case 2: {
- thread th2 (&LightBulb_Skeleton::___turnOn, std::ref(skel), skel);
+ thread th2 (&LightBulb_Skeleton::___turnOn, skel, skel);
th2.detach(); break;
}
case 3: {
- thread th3 (&LightBulb_Skeleton::___getState, std::ref(skel), skel);
+ thread th3 (&LightBulb_Skeleton::___getState, skel, skel);
th3.detach(); break;
}
case 4: {
- thread th4 (&LightBulb_Skeleton::___setColor, std::ref(skel), skel);
+ thread th4 (&LightBulb_Skeleton::___setColor, skel, skel);
th4.detach(); break;
}
case 5: {
- thread th5 (&LightBulb_Skeleton::___setTemperature, std::ref(skel), skel);
+ thread th5 (&LightBulb_Skeleton::___setTemperature, skel, skel);
th5.detach(); break;
}
case 6: {
- thread th6 (&LightBulb_Skeleton::___getBrightness, std::ref(skel), skel);
+ thread th6 (&LightBulb_Skeleton::___getBrightness, skel, skel);
th6.detach(); break;
}
case 7: {
- thread th7 (&LightBulb_Skeleton::___getHue, std::ref(skel), skel);
+ thread th7 (&LightBulb_Skeleton::___getHue, skel, skel);
th7.detach(); break;
}
case 8: {
- thread th8 (&LightBulb_Skeleton::___getSaturation, std::ref(skel), skel);
+ thread th8 (&LightBulb_Skeleton::___getSaturation, skel, skel);
th8.detach(); break;
}
case 9: {
- thread th9 (&LightBulb_Skeleton::___getTemperature, std::ref(skel), skel);
+ thread th9 (&LightBulb_Skeleton::___getTemperature, skel, skel);
th9.detach(); break;
}
case 10: {
- thread th10 (&LightBulb_Skeleton::___getBrightnessRangeLowerBound, std::ref(skel), skel);
+ thread th10 (&LightBulb_Skeleton::___getBrightnessRangeLowerBound, skel, skel);
th10.detach(); break;
}
case 11: {
- thread th11 (&LightBulb_Skeleton::___getBrightnessRangeUpperBound, std::ref(skel), skel);
+ thread th11 (&LightBulb_Skeleton::___getBrightnessRangeUpperBound, skel, skel);
th11.detach(); break;
}
case 12: {
- thread th12 (&LightBulb_Skeleton::___getHueRangeLowerBound, std::ref(skel), skel);
+ thread th12 (&LightBulb_Skeleton::___getHueRangeLowerBound, skel, skel);
th12.detach(); break;
}
case 13: {
- thread th13 (&LightBulb_Skeleton::___getHueRangeUpperBound, std::ref(skel), skel);
+ thread th13 (&LightBulb_Skeleton::___getHueRangeUpperBound, skel, skel);
th13.detach(); break;
}
case 14: {
- thread th14 (&LightBulb_Skeleton::___getSaturationRangeLowerBound, std::ref(skel), skel);
+ thread th14 (&LightBulb_Skeleton::___getSaturationRangeLowerBound, skel, skel);
th14.detach(); break;
}
case 15: {
- thread th15 (&LightBulb_Skeleton::___getSaturationRangeUpperBound, std::ref(skel), skel);
+ thread th15 (&LightBulb_Skeleton::___getSaturationRangeUpperBound, skel, skel);
th15.detach(); break;
}
case 16: {
- thread th16 (&LightBulb_Skeleton::___getTemperatureRangeLowerBound, std::ref(skel), skel);
+ thread th16 (&LightBulb_Skeleton::___getTemperatureRangeLowerBound, skel, skel);
th16.detach(); break;
}
case 17: {
- thread th17 (&LightBulb_Skeleton::___getTemperatureRangeUpperBound, std::ref(skel), skel);
+ thread th17 (&LightBulb_Skeleton::___getTemperatureRangeUpperBound, skel, skel);
th17.detach(); break;
}
default:
extern "C" void* createLightBulb_Skeleton(void** params) {
// Args: *_mainObj, int _portSend, int _portRecv
- return new LightBulb_Skeleton((LightBulb*) params[0], *((int*) params[0]), *((int*) params[1]));
+ return new LightBulb_Skeleton((LightBulb*) params[0], *((int*) params[1]), *((int*) params[2]));
}
extern "C" void destroyLightBulb_Skeleton(void* t) {