* @version 1.0
* @since 2016-06-16
*/
-public class IoTSlave {
+public final class IoTSlave {
/**
* IoTSlave class properties
FileInputStream fis = new FileInputStream(file);
prop.load(fis);
} catch (IOException ex) {
- System.out.println("IoTMaster: Error reading config file: " + strCfgFileName);
+ RuntimeOutput.print("IoTMaster: Error reading config file: " + strCfgFileName, BOOL_VERBOSE);
ex.printStackTrace();
}
- System.out.println("IoTMaster: Extracting information from config file: " + strCfgFileName);
+ RuntimeOutput.print("IoTMaster: Extracting information from config file: " + strCfgFileName, BOOL_VERBOSE);
// Initialize constants from config file
STR_JAR_FILE_PATH = prop.getProperty("JAR_FILE_PATH");
STR_OBJ_CLS_PFX = prop.getProperty("OBJECT_CLASS_PREFIX");
CAPAB_BASED_RMI = true;
}
- System.out.println("JAR_FILE_PATH=" + STR_JAR_FILE_PATH);
- System.out.println("OBJECT_CLASS_PREFIX=" + STR_OBJ_CLS_PFX);
- System.out.println("INTERFACE_PREFIX=" + STR_INTERFACE_PFX);
- System.out.println("SKEL_CLASS_SUFFIX=" + SKEL_CLASS_SUFFIX);
- System.out.println("STUB_CLASS_SUFFIX=" + STUB_CLASS_SUFFIX);
- System.out.println("CAPAB_BASED_RMI=" + CAPAB_BASED_RMI);
- System.out.println("IoTMaster: Information extracted successfully!");
+ RuntimeOutput.print("JAR_FILE_PATH=" + STR_JAR_FILE_PATH, BOOL_VERBOSE);
+ RuntimeOutput.print("OBJECT_CLASS_PREFIX=" + STR_OBJ_CLS_PFX, BOOL_VERBOSE);
+ RuntimeOutput.print("INTERFACE_PREFIX=" + STR_INTERFACE_PFX, BOOL_VERBOSE);
+ RuntimeOutput.print("SKEL_CLASS_SUFFIX=" + SKEL_CLASS_SUFFIX, BOOL_VERBOSE);
+ RuntimeOutput.print("STUB_CLASS_SUFFIX=" + STUB_CLASS_SUFFIX, BOOL_VERBOSE);
+ RuntimeOutput.print("CAPAB_BASED_RMI=" + CAPAB_BASED_RMI, BOOL_VERBOSE);
+ RuntimeOutput.print("IoTMaster: Information extracted successfully!", BOOL_VERBOSE);
}
/**
inStream.close();
socket.close();
RuntimeOutput.print("IoTSlave: Closing!", BOOL_VERBOSE);
- // We have to continuously loop because we are preserving our stubs and skeletons
- //while(true) { }
} catch (IOException |
ClassNotFoundException |