hardwaredb/include/sethardware.h
2025-01-29 20:55:57 -07:00

29 lines
997 B
C++

// void setCPU(){};
/* this function's Incoming arguments are a pointer to the Hardware class
"Hardware *pHardware" and the new mainclock speed
*/
void setHardwaremanufacturer(Hardware *pHardware, std::string mmanufacturer) {
// cout << "Coming from the setHardwaremanufacturer function in setHardware" << endl;
pHardware->manufacturer = mmanufacturer;
// cout << "Leaving setHardwaremanufacturer()\n\n";
}
void setHardwarereleasedyear(Hardware *pHardware, int mreleasedyear) {
pHardware->releasedyear = mreleasedyear;
}
void setHardwaremodel(Hardware *pHardware, std::string mmodel) {
pHardware->model = mmodel;
}
void Hardwaredictadd(CPU *pHardware, std::string mkey, std::string mvalue) {
// cout << "The incoming key/value is: " << mkey << "/" << mvalue << endl;
// cout << "\nThe current manufacturer is: " << pHardware->HardwareSpecs[mkey] << endl;
pHardware->HardwareSpecs[mkey] = mvalue;
// cout << "The new manufacturer is: " << pHardware->HardwareSpecs[mkey];
}