Question: In c + + , need help with compile files Instructions Design the class doctorType, inherited from the class personType, defined in Chapter 1 0

In c++, need help with compile files
Instructions
Design the class doctorType, inherited from the class personType, defined in Chapter 10, with an additional data member to store a doctors specialty. Add appropriate constructors and member functions to initialize, access, and manipulate the data members.
Design the class billType with data members to store a patients ID and a patients hospital charges, such as pharmacy charges for medicine, doctors fee, and room charges. Add appropriate constructors and member functions to initialize, access, and manipulate the data members. If no value is provided for a charge, it should default to 0.
Design the class patientType, inherited from the class personType, defined in Chapter 10, with additional data members to store a patients ID, age, date of birth, attending physicians name, the date when the patient was admitted in the hospital, and the date when the patient was discharged from the hospital. (Use the class dateType to store the date of birth, admit date, discharge date, and the class doctorType to store the attending physicians name.) Add appropriate constructors and member functions to initialize, access, and manipulate the data members.
Be careful! The dateType object and the patientType object might accept different date formats.
Write a program to test your classes.
I have a problem regarding my billType and my patientType, it says it had a runtime error and couldn't compile files. here they are below, I can't put the .h files or the main.cpp because they are too long, but as long as it includes them it is ok.
billtypeimp.cpp
#include "billType.h"
billType::billType(int ID, double Med, double pDrF, double room_Charge)
{
PtID = ID;
MedChg = Med;
DrF = pDrF;
RmChg = room_Charge;
}
void billType::setMedChg(double Med)
{
MedChg = Med;
}
double billType::getMedChg() const
{
return MedChg;
}
void billType::setDrF(double pDrF)
{
DrF = pDrF;
}
double billType::getDrF() const
{
return DrF;
}
void billType::setRmChg(double pRmChg)
{
RmChg = pRmChg;
}
double billType::getRmChg() const
{
return RmChg;
}
patientypeimp.cpp
#include
#include "patientType.h"
patientType::patientType(string First, string Last, int ID, int PtAge, dateType DoB, dateType pAdmtDt, dateType pDcDt, doctorType pDr)
{
setName(First,Last);
PtID = ID;
Age = PtAge;
dtBth = DoB;
admtDt = pAdmtDt;
DcDt = pDcDt;
Dr = pDr;
}
void patientType::setPtID(int ID)
{
PtID = ID;
}
void patientType::setAge(int pAge)
{
Age = pAge;
}
void patientType::setDoB(dateType DoB)
{
dtBth = DoB;
}
void patientType::setAdmtDt(dateType pAdmtDt)
{
admtDt = pAdmtDt;
}
void patientType::setDcDt(dateType pDcDt)
{
DcDt = pDcDt;
}
void patientType::setPcNm(doctorType pDr)
{
Dr = pDr;
}
int patientType::getPtID()
{
return PtID;
}
int patientType::getAge()
{
return Age;
}
dateType patientType::getDoB()
{
return dtBth;
}
dateType patientType::getAdmtDt()
{
return admtDt;
}
dateType patientType::getDcDt()
{
return DcDt;
}
string patientType::getPcNm()
{
return Dr.getfName().append(""+ Dr.getlName());
}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!