using namespace std;
Room_Skeleton::Room_Skeleton(Room *_mainObj, int _portSend, int _portRecv) {
- // Logging
- int i=0;
- string file = "Room_Skeleton_cpp" + to_string(i) + ".log";
- while (ifstream(file.c_str())) {
- i++;
- file = "Room_Skeleton_cpp" + to_string(i) + ".log";
- }
- log.open(file);
- log << "Port send: " << _portSend << endl;
- log << "Port receive: " << _portRecv << endl;
bool _bResult = false;
mainObj = _mainObj;
rmiComm = new IoTRMICommServer(_portSend, _portRecv, &_bResult);
- log << "Established connection with slave! Wait request invoke now..." << endl;
IoTRMIUtil::mapSkel->insert(make_pair(_mainObj, this));
IoTRMIUtil::mapSkelId->insert(make_pair(_mainObj, objectId));
rmiComm->registerSkeleton(objectId, &methodReceived);
extern "C" void initRoom_Skeleton(void* t) {
}
+
int main() {
return 0;
}